# Transistor

> An electrically controlled switch, the basic building block of every chip.

- Level: Intermediate
- Topics: Hardware
- URL: https://tidbit.legios.com.ar/transistor/
- In Spanish: [Transistor](https://tidbit.legios.com.ar/es/transistor/)

A **transistor** is a switch with no moving parts. It has three connections: current wants to flow between two of them (the **source** and the **drain**), and a small voltage on the third (the **gate**) decides whether it can. Gate on, current flows; gate off, it stops. On means 1, off means 0, and that is where the ones and zeros of computing physically live.

One switch does not do much. But wire a few together and you get **logic gates**, little circuits that answer questions like "are both inputs on?" (AND) or "is at least one on?" (OR). Combine gates and you can add numbers, compare them, and store a bit of memory. Stack that up by the billion and you have a CPU. The kind used in almost every modern chip is the **MOSFET**, built directly into silicon.

The first transistor was built at Bell Labs in 1947, a fist-sized device that replaced fragile vacuum tubes. Since then they have shrunk so much that a modern phone chip holds tens of billions of them, so small that more than a thousand would fit side by side across a human hair. Smaller transistors switch faster, use less energy and fit more per chip, which is the story Moore's law describes.

## An analogy

A water tap controlled by a tiny lever. Pressure is always waiting in the pipe; flick the lever and water flows, release it and the flow stops. A computer is billions of these taps opening and closing in patterns, billions of times per second.

## Keep in mind

- A switch controlled by voltage: gate on lets current through, gate off blocks it.
- On and off are the 1s and 0s of digital computing.
- Combined into logic gates, they add, compare and remember.
- Invented in 1947; modern chips hold billions of them.

## Go deeper

- [Transistor on Wikipedia](https://en.wikipedia.org/wiki/Transistor)
- [MOSFET on Wikipedia](https://en.wikipedia.org/wiki/MOSFET)

## Related terms

- [CPU](https://tidbit.legios.com.ar/cpu/): The chip that runs your programs, one instruction after another, very fast.
- [Chip](https://tidbit.legios.com.ar/semiconductor-chip/): A sliver of silicon carrying billions of tiny switches that compute and remember.
