Hex Calculator
Enter two hex numbers and choose an operation.
Operation
AND, OR and XOR compare the numbers digit by digit.
Digits 0–9 and A–F, with an optional 0x; a leading minus sign is allowed.
Digits 0–9 and A–F, with an optional 0x; a leading minus sign is allowed.
Try
Result
You entered
Decimal
Binary
Show the work
Hex to decimal
Each hex digit is worth a power of , counting from at the right, with A to F standing for 10 to 15. Converting both numbers to decimal lets the operation be done with ordinary arithmetic.
Using
Division with a remainder
Dividing by gives a whole-number quotient and a remainder that is smaller than the divisor in size.
Using
Decimal to hex
Write the quotient and the remainder in hex.
Result
So gives quotient and remainder .