User Rating 0.0
Total Usage 0 times
0b
0b
Is this tool helpful?

Your feedback helps us improve.

About

Binary addition is the foundational arithmetic operation of every digital processor. Errors in manual binary computation propagate exponentially: a single misplaced carry bit in a 32-bit word corrupts the entire result. This tool computes the sum of two unsigned binary integers up to 64 bits using full-adder logic - the same S = A B Cin circuit equation implemented in hardware ALUs. It displays every intermediate carry bit so you can trace propagation column by column, exactly as you would on paper but without the transcription mistakes.

The calculator assumes unsigned (non-negative) integers in pure base-2 positional notation. Leading zeros are tolerated but stripped from output. Results exceeding 64 bits (overflow beyond 264 1) are still computed correctly but lose JavaScript integer precision above 253 1 for the decimal readout due to IEEE 754 double-precision limits.

binary addition binary calculator binary math base-2 arithmetic full adder carry propagation binary to decimal

Formulas

The full-adder computes a single-bit sum and carry-out from two input bits and a carry-in:

S = A B Cin
Cout = (A B) (Cin (A B))

Where A and B are the input bits at position i, Cin is the carry from position i 1, S is the sum bit written at position i, and Cout is the carry forwarded to position i + 1. The symbol denotes XOR (exclusive OR), denotes AND, and denotes OR.

Decimal conversion from binary uses positional weighting:

N = n1i=0 bi 2i

Where bi is the bit value (0 or 1) at position i counted from the right (LSB = 0), and n is the total number of bits.

Reference Data

Bit WidthMax Unsigned Value (Decimal)Max BinaryCommon Use
4-bit (Nibble)151111Single hex digit, BCD
8-bit (Byte)25511111111ASCII, pixel channels
12-bit4095111111111111ADC resolution
16-bit (Word)65,5351111111111111111Unicode BMP, ports
20-bit1,048,57511111111111111111111Real-mode addressing
24-bit16,777,215111111111111111111111111RGB color, audio
32-bit (DWord)4,294,967,29532 onesIPv4, float32, ARM
48-bit281,474,976,710,65548 onesMAC addresses
53-bit9,007,199,254,740,99153 onesJS safe integer limit
64-bit (QWord)18,446,744,073,709,551,61564 onesx86-64, uint64
128-bit3.4 × 1038128 onesIPv6, UUID, AES
256-bit1.16 × 1077256 onesSHA-256, elliptic curves
Binary Addition Rules (Single-Bit)
0 + 00carry 0No carry produced
0 + 11carry 0No carry produced
1 + 01carry 0No carry produced
1 + 10carry 1Carry propagates left
1 + 1 + 11carry 1Full adder with carry-in

Frequently Asked Questions

Carry propagation proceeds from the least significant bit (rightmost) to the most significant bit (leftmost), exactly like decimal addition. When two bits and an incoming carry sum to 2 or 3 (binary 10 or 11), a carry of 1 propagates to the next higher column. In the worst case (e.g., 1111 + 0001), the carry ripples through every bit position. This ripple-carry delay is the reason hardware uses carry-lookahead adders for speed.
The sum may require one extra bit. For example, 1111 (15) + 0001 (1) = 10000 (16), growing from 4 bits to 5. This tool always displays the full result. In fixed-width hardware (e.g., 8-bit registers), this extra bit is the overflow/carry flag. If your target architecture has a fixed width, you must check whether the result exceeds it.
JavaScript uses IEEE 754 double-precision floating point for its Number type, which provides exactly 53 bits of integer mantissa. The maximum safe integer is 253 1 = 9,007,199,254,740,991. Binary values wider than 53 bits convert correctly as binary strings, but their decimal representation may lose precision. This tool uses BigInt internally for decimal conversion when available, maintaining accuracy for all 64-bit inputs.
XOR () gives the sum bit without carry: 1 1 = 0. Bitwise OR gives 1 1 = 1. Neither propagates carries. True binary addition uses the full-adder equation where each column's carry feeds the next. For example, 11 + 11 = 110 (decimal 6), but 11 XOR 11 = 00 and 11 OR 11 = 11. They are fundamentally different operations.
This calculator operates on unsigned binary integers. For two's complement signed addition, the bit-level mechanics are identical - the same full-adder circuit adds signed numbers. The difference is interpretation: the most significant bit represents 2n1 instead of +2n1. You can use this tool for the raw addition, then manually interpret the result in two's complement if your fixed bit width's MSB is 1.
Hexadecimal (base-16) is a compact notation for binary where each hex digit maps to exactly 4 binary bits (a nibble). For example, 0xF = 1111, 0xA = 1010. You can convert your hex values to binary, add them here, then group the result bits into nibbles to read the hex answer. The addition rules are identical regardless of notation.