A circuit board, representing logic gates.

The tiny building blocks that let computers make decisions.

What a logic gate is

A logic gate is a basic building block of digital electronics. It takes one or more inputs, each of which is one of two values - usually thought of as on or off, or one and zero - and produces a single output based on a fixed logical rule. By following that rule, the gate 'decides' what its output should be given its inputs. These simple decision-making elements are the foundation on which all digital circuits, including computers, are built.

Binary inputs and outputs

Logic gates work with binary values, meaning each input and output is one of just two possibilities. This fits perfectly with how digital electronics represent information using two distinct states. A gate reads its binary inputs and produces a binary output, so everything a gate does is in terms of these two-valued signals. Because computers represent all data in binary, logic gates are a natural match for processing that data at the hardware level.

Different kinds of gates

There are several basic types of logic gate, each following a different logical rule for turning inputs into an output. Some produce an output only when all their inputs are on; others when at least one input is on; and some simply reverse their input. Each type embodies a simple, well-defined logical operation. From this small set of basic gates, an enormous variety of behavior can be constructed by combining them in different ways.

Combining gates

The real power of logic gates comes from connecting them together. The output of one gate can feed into the input of another, and by wiring many gates in the right arrangement, circuits can be built that perform useful operations - from simple arithmetic to complex decision-making. Everything a computer's processor does is ultimately carried out by vast numbers of logic gates working together, each doing its tiny part of the overall computation.

From gates to computers

Modern processors contain an astonishing number of logic gates, built from tiny electronic switches packed onto chips. Layer upon layer of combined gates create the circuits that add numbers, store values, and control the flow of a program. In this way, the simple, two-valued logic of individual gates scales up into the full capability of a computer. The humble logic gate is, quite literally, what computers are made of at the most basic level.

Why it matters

Logic gates are the fundamental building blocks of all digital technology, the point where electronics becomes computation. Understanding what a logic gate is - a simple element that turns binary inputs into a binary output by a logical rule - reveals how computers are built from the ground up. For anyone curious about what lies beneath software and circuits, the logic gate is one of the most foundational concepts there is.

See also: What is a CPU register? Explained simply, What is bytecode? Explained simply.

Sources

Published date reflects the original event date (2023-08-01). This article is original Skillo editorial written from the sources above; facts were verified in September 2026.

Skillo Staff

Skillo Staff

All stories by: Skillo Staff

Leave a Reply