CD4011 (CD4011B): the quad 2-input NAND gate chip, live
The CD4011 is a 4000-series CMOS chip with four 2-input NAND gates: J = NOT (A AND B), K = NOT (C AND D), L = NOT (E AND F) and M = NOT (G AND H). It runs from 3 V to 18 V, and its pinout is not the same as the 7400's. This live chip has all four gates.
TI's datasheet (from Harris Semiconductor) describes the CD4011B as part of a family of CMOS NAND gates with buffered inputs and outputs, alongside the dual 4-input CD4012B and the triple 3-input CD4023B, for supplies from 3 V to 18 V. The logic is the same as the 7400, but the pins are not: the CD4011 puts two outputs next to each other in the middle of each side (pins 3 and 4, and 10 and 11), with each gate's inputs on the outer pins, and it calls its supply pins VDD and VSS. The CD4001 NOR and CD4081 AND chips use the same pins. A 7400 dropped into a CD4011 socket, or the other way round, will not work. The wide supply range is the CD4011's draw for battery projects, and a NAND gate wired with an RC network makes a simple oscillator, a common use for the spare gates. Each gate here is the CMOS NAND. All 256 combinations of the eight inputs are checked before the page is built.
Open this circuit in the lab →
What you need
- 4× 2-input NAND: J from A, B; K from C, D; L from E, F; M from G, H
Step by step
- Power the chip:
VDDon pin 14 andVSSon pin 7, anywhere from 3 V to 18 V. - Each gate has two inputs and one output; find their pins in the pinout below.
- Tie every unused input to VCC or GND: a floating CMOS input can drift and draw current.
- Set all two inputs of one gate to 1: its output goes to 0. Any 0 on an input gives 1.
CD4011 pinout
| Pin | Name | Pin | Name |
|---|---|---|---|
| 1 | A | 14 | VDD |
| 2 | B | 13 | H |
| 3 | J | 12 | G |
| 4 | K | 11 | M |
| 5 | C | 10 | L |
| 6 | D | 9 | F |
| 7 | VSS | 8 | E |
2-input NAND truth table (each gate)
| A | B | Y |
|---|---|---|
| 0 | 0 | 1 |
| 0 | 1 | 1 |
| 1 | 0 | 1 |
| 1 | 1 | 0 |
Pin numbers and names are from TI's CD4011B (SCHS021D) datasheet, checked 2026-10-25. Each gate is independent; the chip only shares the power pins.
You can also read the full theory in the lesson on the NAND gate. Prefer to build it yourself from scratch? Open the digiwleea lab and place the gates on the canvas, or start from the logic gate simulator.
Build more parts from gates
Each of these is one step from a transistor to a working CPU. Build every gate from CMOS transistors and work all the way up in the free digiwleea lab, with the free theory reference alongside.
Open the CD4011 quad 2-input NAND chip in the lab →Frequently asked
What is the CD4011?
A 4000-series CMOS chip with four 2-input NAND gates, for supplies from 3 V to 18 V. TI's CD4011B datasheet lists it with the CD4012B (dual 4-input) and CD4023B (triple 3-input) NAND gates.
What is the CD4011 pinout?
Pin 1 A, 2 B, 3 J, 4 K, 5 C, 6 D, 7 VSS, 8 E, 9 F, 10 L, 11 M, 12 G, 13 H, 14 VDD, with J = NOT (A B), K = NOT (C D), L = NOT (E F) and M = NOT (G H).
Is the CD4011 the same as the 7400?
Same logic, different pinout and supply range. Both have four 2-input NAND gates, but the CD4011's outputs are on pins 3, 4, 10 and 11, while the 7400's are on 3, 6, 8 and 11, so they are not interchangeable in a socket.
Why use a CD4011 instead of a 74HC00?
Mainly for its supply range: the CD4011 works from 3 V to 18 V, so it suits 9 V or 12 V battery circuits, while the 74HC00 is limited to 2 V to 6 V. The 74HC00 is faster.