Truth Table Generator Online
Enter a Boolean formula — and get a complete truth table with every input set. The tool runs right in your browser, with no install and no data sent to a server.
Examples: (a AND b) OR NOT c · a XOR b · (a NAND b) NOR c
How to use
Write the formula with lowercase letters and operators. Operator precedence follows boolean algebra: NOT first, then AND and NAND, then XOR, then OR and NOR. Parentheses change the order:
- NOT — negation:
NOT a,!a - AND — logical AND:
a AND b,a & b - OR — logical OR:
a OR b,a | b - XOR — exclusive OR:
a XOR b,a ^ b - NAND — NAND:
a NAND b - NOR — NOR:
a NOR b
Up to 8 variables (a–h) are supported: the table will contain 2n rows.
How to read a truth table
Each row of the table is one input set. The leftmost column is the first variable of the formula, the rightmost is the result. All 2n sets are listed in binary counting order from 0 to 2n−1, so nothing is missed. To learn more about reading truth tables, see the Exclusive OR (XOR) article and the AND and NAND datasheets.
Related tools and materials
- Logic circuit simulator — build a circuit that matches your formula and verify it.
- Number base converter — convert numbers between binary, decimal and hexadecimal.
- Logic Gates AND, OR, NOT — an introduction to Boolean algebra.
- Knowledge library — articles and component datasheets on circuitry.