Everyday utility

Binary Calculator

Calculate number converted to binary, hex, or octal from Decimal number, Target base, with the key formulas and caveats needed to interpret the result correctly.

Last reviewed May 18, 2026 by ToolSpilo Editorial Team.

Review method: Reviewed against the implemented binary place values and bitwise operations, displayed formulas, and worked examples.

Calculator tool

How this calculator works

Use the explanation to understand the formula, assumptions, and practical limits behind the calculator result.

Binary Uses Only Two Digits

Binary is a number system that uses only 0 and 1. Each place is worth twice the place to its right:

Binary placeValue
202^01
212^12
222^24
232^38

So 1011 means 8+0+2+1=118 + 0 + 2 + 1 = 11 in decimal.

How Binary Addition Works

Binary addition follows the same idea as decimal addition, but it carries sooner because only two digits exist. In binary, 1 + 1 = 10, which means write 0 and carry 1 to the next place.

What This Calculator Helps With

Use it to add, subtract, multiply, divide, or compare binary values and to check bitwise operations such as AND, OR, and XOR. These operations matter in programming, networking, and digital electronics because computers store information as bits.

Reading the Result

If a result looks unfamiliar, convert it back by adding the place values of the 1 bits. For example, 11001 equals 16+8+1=2516 + 8 + 1 = 25.

Frequently asked questions

How do you convert a decimal number to binary?

One simple method is repeated division by 2. Keep each remainder, then read the remainders from bottom to top. For example, decimal 13 becomes binary 1101 because 8+4+1=138 + 4 + 1 = 13.

What is two's complement and why is it used for negative numbers?

Computers often store negative integers with a method called two's complement so addition and subtraction can use the same basic hardware. For a beginner, the main thing to remember is that the bit width matters: the same bit pattern can mean a different value in signed and unsigned form.

What are bitwise operations and where are they used?

Bitwise operations compare matching bits one position at a time. AND keeps a 1 only when both bits are 1, OR keeps a 1 when either bit is 1, and XOR keeps a 1 when the bits differ. They are useful for masks, flags, and low-level data work.

How does binary relate to hexadecimal in programming?

Hexadecimal is a shorter way to write binary because one hex digit matches exactly four binary bits. For example, binary 1111 is hex F, so long bit strings become much easier to read.