Skip to main content

NAND GATE

Outputs ON unless ALL inputs are ON. The inverse of an AND gate. NAND is functionally complete, any logic circuit can be built using only NAND gates.

NAND Gate in Minecraft

Truth Table

Input AInput BOutput
0 (OFF)0 (OFF)1 (ON)
0 (OFF)1 (ON)1 (ON)
1 (ON)0 (OFF)1 (ON)
1 (ON)1 (ON)0 (OFF)

Overview: what the NAND Gate is and does

Outputs ON unless ALL inputs are ON. The inverse of an AND gate. NAND is functionally complete, any logic circuit can be built using only NAND gates.

In plain terms, the output is on in every case except when both inputs are on. NAND is functionally complete: any logic circuit whatsoever can be built from NAND gates alone, which makes it a favourite primitive for compact redstone computers.

This page describes the gate as it behaves in Java Edition 1.21; the truth table and timings below match vanilla redstone exactly.

How it works: the redstone mechanics

Across its four input combinations the output is on in 3 cases — A off with B off, A off with B on, and A on with B off — and off in the remaining 1.

Expressed as boolean algebra that is output = NOT (A AND B).

A torch-based NAND adds roughly 2 redstone ticks through its inverter-and-merge stages.

Because redstone signals are just on or off, "on" here means a powered line (signal 1-15) and "off" means an unpowered line (signal 0); the gate cares only about presence or absence of power, not its exact strength.

How to build it

  1. 1Place two solid blocks side by side.
  2. 2Run input A into the first block and place a torch on top (NOT A).
  3. 3Run input B into the second block and place a torch on top (NOT B).
  4. 4Merge the two torch outputs with redstone dust (OR of NOT A and NOT B).
  5. 5By De Morgan's Law: NOT(A) OR NOT(B) = NOT(A AND B) = NAND.
  6. 6Verify it against the truth table: setting the inputs to OFF and OFF should drive the output ON. Walk through every input combination once to confirm the gate matches the table above.

Uses & applications

  • NAND is functionally complete: any logic circuit whatsoever can be built from NAND gates alone, which makes it a favourite primitive for compact redstone computers.
  • Torch-based NAND (2 torches + OR merge) — a practical build choice for this gate.
  • AND gate with trailing NOT gate — a practical build choice for this gate.
  • Comparator-based NAND (subtract mode inverted) — a practical build choice for this gate.

Tips & common mistakes

  • !Keep your inputs isolated with repeaters if signals are flowing back into each other; uncontrolled backflow between dust lines is the most common reason a gate reads the wrong value.
  • !Remember the propagation cost: A torch-based NAND adds roughly 2 redstone ticks through its inverter-and-merge stages. If you chain several gates, those ticks add up and can desynchronise a fast circuit.
  • !When a multi-gate circuit misbehaves, test each gate in isolation against its own truth table before assuming the wiring between them is at fault.

NAND Gate FAQ

What does a NAND Gate do in Minecraft?

A NAND Gate outputs a signal where the output is on in every case except when both inputs are on. In boolean terms, output = NOT (A AND B).

What is the truth table of a NAND Gate?

Across its four input combinations the output is on in 3 cases — A off with B off, A off with B on, and A on with B off — and off in the remaining 1. The boolean expression is output = NOT (A AND B).

How do you build a NAND Gate with redstone?

Place two solid blocks side by side. Run input A into the first block and place a torch on top (NOT A). Common variants include torch-based NAND (2 torches + OR merge) and AND gate with trailing NOT gate.

How much delay does a NAND Gate add?

A torch-based NAND adds roughly 2 redstone ticks through its inverter-and-merge stages. That matters most in clocks and adders where every redstone tick counts.

Why is the NAND gate called functionally complete?

A gate is functionally complete if every other logic function can be built from copies of it alone. NAND qualifies: you can make NOT, AND, OR and every other gate purely from NAND gates, which is why processors are often described in terms of NAND counts.

Back to all logic gates