Hex addition
Every carry is kept, so the result can be 1 digit longer than the longest number: FFFF + 1 = 10000.
Add or subtract hexadecimal numbers with carries, borrows and decimal and binary checks.
Enter your values below to get started.
Letters are case-insensitive: beef and BEEF are the same number.
Pick Subtract to compute the 1st number minus all the others.
Set a Register width to see what an 8-bit or 32-bit CPU register keeps.
Open the Table tab to see each column's total in decimal.
A hex sum calculator adds or subtracts numbers written in base 16 (digits 0–9 and A–F) and shows each carry or borrow column by column. Enter 2 to 50 hexadecimal numbers to get the hex result, its decimal, binary and octal values, a long-addition layout, and an optional 8-, 16-, 32- or 64-bit register view that flags a carry out.
A hex sum is the result of adding numbers written in hexadecimal (base 16), where each column holds a digit from 0 to F and a column total of 16 or more carries 1 to the next column. The hex sum 3A7 + 1C9 equals 570, which is 935 + 457 = 1,392 in decimal.
Hexadecimal uses 16 digits: 0–9 for values 0 to 9 and A, B, C, D, E, F for values 10 to 15. Each column has a place value of 16n: 1, 16, 256, 4,096 and 65,536. IBM popularized the A–F digits with the System/360 in 1964, and the C programming language added the 0x prefix used in code today.
One hex digit stands for exactly 4 bits (a nibble), so 2 hex digits describe 1 byte (8 bits) and 8 hex digits describe a 32-bit word.
The hex sum calculator right-aligns the numbers, adds each column from the right in decimal, writes the total minus 16 when the total reaches 16, and carries 1 left. Subtraction works the same way with borrows: a top digit smaller than the bottom digit borrows 16 from the next column.
The calculator strips 0x, # or a trailing h and checks for the digits 0–9 and A–F.
Column total = digit values + carry in. 7 + 9 = 16 writes 0 and carries 1.
With 8 bits the calculator keeps 2 hex digits; anything beyond is the carry out.
The result is shown in decimal (base 10), binary (base 2) and octal (base 8) with exact big-integer math.
Each hex column follows one formula: digit = (a + b + cin) mod 16 and carry = ⌊(a + b + cin) ÷ 16⌋. For A + C + 1 = 10 + 12 + 1 = 23, the digit is 23 − 16 = 7 and the carry is 1.
The value of a hex number is the sum of each digit times 16 to the power of its position.
Hex subtraction writes (a − b − borrow) when that value is 0 or more, and (a + 16 − b − borrow) with a new borrow when the value is negative. 3 − 9 borrows: 3 + 16 − 9 = 10 = A.
There are 4 types of hex sums: unlimited hex addition, hex subtraction, fixed-width (modular) hex sums, and negative hex differences. The same digits give different answers depending on the type: C8 + 64 is 12C with unlimited width but 2C in an 8-bit register.
Every carry is kept, so the result can be 1 digit longer than the longest number: FFFF + 1 = 10000.
Borrows replace carries: 7F3 − 2A9 = 54A, with 1 borrow in the 160 column.
Only n bits are kept, which is addition mod 2n. CPU registers, checksums and hash functions work this way.
When the result is below 0, the calculator shows −54A. In a register the same value wraps to its two's complement, FAB6 in 16 bits.
To add hex numbers by hand, convert each column's digits to decimal, add them with the carry, subtract 16 when the total is 16 or more, write the digit and carry 1. Here is 3A7 + 1C9:
A hex sum and a binary sum always give the same result: 16 = 24, so every hex digit maps to exactly 4 bits. A carry out of a hex column is the same event as a carry out of the matching 4-bit group in binary.
Programmers write memory addresses, colors and machine code in hex for this reason: 1 byte = 2 hex digits, 1 kibibyte (KiB) = 40016 = 1,024 bytes, and the 32-bit maximum is FFFFFFFF = 4,294,967,295.
To use the hex sum calculator, type 2 or more hex numbers, choose Add all or Subtract, pick a register width if you need one, and press Calculate. The result card shows the hex answer with decimal, binary and octal values; the tabs show the steps, the long addition and a column table.
One per line or separated by spaces, commas or +. Prefixes like 0x are fine.
Add all, or Subtract to take the 2nd and later numbers away from the 1st.
8, 16, 32 or 64 bits shows what a register keeps and whether a carry left it.
The Long addition tab marks each carry or borrow in orange.
Hex sums appear wherever computers show raw bytes. There are 5 common uses:
Common hexadecimal additions and subtractions with the decimal check.
| Problem | Hex result | Decimal check | Calculator |
|---|---|---|---|
| 9 + 7 | 10 | 9 + 7 = 16 | |
| 3A7 + 1C9 | 570 | 935 + 457 = 1,392 | |
| FFFF + 1 | 10000 | 65,535 + 1 = 65,536 | |
| BEEF + CAFE | 189ED | 48,879 + 51,966 = 100,845 | |
| A9 + 7D + 3C | 162 | 169 + 125 + 60 = 354 | |
| 7F3 − 2A9 | 54A | 2,035 − 681 = 1,354 | |
| C8 + 64 (8-bit) | 2C, carry out | 200 + 100 = 300 = 256 + 44 |
Solve each one by hand, then reveal the answer or check it in the calculator.
Add 4B and 3F.
Add 1F4 and 2EE.
Add FF and FF.
Add ABC and DEF.
Subtract 1 from 1000.
In a 32-bit register, add FFFFFFF0 and 20. What does the register hold?
Discover 67 free sum calculators across different categories. Find the right calculator for your needs.
Try a different name or choose another category.
A hex sum calculator is an online tool that adds or subtracts hexadecimal (base-16) numbers and shows each carry or borrow. This hex sum calculator handles 2 to 50 numbers and gives the result in hex, decimal, binary and octal.
Add hex numbers column by column from the right: convert the digits to decimal, add them with the carry, and when the total is 16 or more write total − 16 and carry 1. 7 + 9 = 16 writes 0 and carries 1.
F + 1 in hex is 10. F equals 15, and 15 + 1 = 16, which is written as 10 in base 16.
FF + 1 in hex is 100, which equals 256 in decimal. In an 8-bit register the result wraps to 00 with a carry out.
Yes, the hex sum calculator subtracts. Pick Subtract and the calculator computes the 1st number minus all the others, with every borrow shown; 7F3 − 2A9 = 54A.
No, hex addition carries at 16 instead of 10. The steps are the same, but 8 + 8 = 10 in hex (16 in decimal) and 9 + 1 = A.
Programmers use hex sums to keep memory addresses, byte offsets and colors short: 1 hex digit equals 4 bits. 0x1000 + 0x24 = 0x1024 is easier to read than the 13-bit binary equivalent.
A hex sum of 2 numbers has at most 1 more digit than the longer number. FFFF + FFFF = 1FFFE, 5 digits from two 4-digit numbers.
A hex sum adds base-16 numbers column by column, carrying 1 whenever a column reaches 16, and the hex sum calculator does this for up to 50 numbers with each carry and borrow shown. Use unlimited width for math, a fixed register width for programming, and the decimal and binary rows to check every answer.
Not sure which setting fits your problem? Answer the questions below.