Decimal to Binary Converter

Convert decimal to binary for programming and computing.

Result

1 dec = 1 bin

Results are provided for general informational purposes only. Always verify important calculations independently. Learn more

Conversion Formula

Convert to binary by dividing by 2

Worked Example:

To convert DEC to BIN:

10 decimal = 1010 binary

Common DEC to BIN Conversions

DECBINDECBIN
1 dec1 bin50 dec50 bin
2 dec2 bin75 dec75 bin
5 dec5 bin100 dec100 bin
10 dec10 bin250 dec250 bin
25 dec25 bin500 dec500 bin

Frequently Asked Questions

When are different number bases used?

Binary (base 2) represents how computers store and process data internally. Hexadecimal (base 16) provides compact representation of binary data for programming, memory addresses, and color codes (#FF0000). Octal (base 8) is used for Unix file permissions (chmod 755). Decimal (base 10) is the human-readable standard for everyday numbers and final calculations.

How do you convert decimal to binary?

Repeatedly divide the decimal number by 2 and track remainders. Read remainders from bottom to top for the binary result. Example: 13 decimal → 13÷2=6 remainder 1, 6÷2=3 remainder 0, 3÷2=1 remainder 1, 1÷2=0 remainder 1 → reading upward: 1101 binary. Alternatively, find powers of 2: 13 = 8+4+1 = 2³+2²+2⁰ = 1101 binary.

Why does hexadecimal use letters A-F?

Hexadecimal needs 16 unique symbols for digits 0-15. Using 0-9 provides ten symbols, so letters A-F represent 10-15 (A=10, B=11, C=12, D=13, E=14, F=15). This allows each hex digit to represent exactly 4 binary bits: F(hex) = 15(decimal) = 1111(binary). Two hex digits (00-FF) perfectly represent a byte (8 bits, 0-255 decimal).

What is the relationship between hex and binary?

Each hexadecimal digit represents exactly 4 binary bits, making conversions easy. Hex F = binary 1111, hex A = binary 1010, hex 5 = binary 0101. To convert: group binary into sets of 4 bits (from right), then convert each group to hex. Example: 11010110 binary = 1101 0110 = D6 hex. This 4:1 relationship makes hex perfect for representing binary data compactly.

How do programmers use different number bases?

Programmers use hex for memory addresses (0x2AF3), color codes (#FF5733), and byte values. Binary for bitwise operations, flags, and masks (checking if bit 3 is set). Octal occasionally for file permissions (chmod 644). Decimal for human-readable values and arithmetic. Most programming languages support literals: 0xFF (hex), 0b1010 (binary), 0o755 (octal), or simply 255 (decimal).

Related Converters