Skip to main content
Back to Resource Library
Math & Number Skills

Binary, Decimal and Hexadecimal Guide

CalConvs Team
June 1, 2026
Math & Number Skills

Quick Answer

DecimalBinaryHexadecimal
25511111111FF
160001000010
10000010100A
  • Binary to decimal: multiply each bit by 2^(its position), add results
  • Decimal to binary: divide by 2 repeatedly, collect remainders bottom up
  • Decimal to hex: divide by 16 repeatedly, use 0-9 then A-F for 10-15

Use the free Binary Converter and Hex Converter on CalConvs for instant conversions.

Binary to Decimal Conversion

Each binary digit (bit) represents a power of 2. Position values (right to left): 1, 2, 4, 8, 16, 32, 64, 128...

Example: Convert binary 10110101 to decimal

Bit10110101
Position76543210
Value128032160401

Sum = 128 + 32 + 16 + 4 + 1 = 181

Decimal to Binary Conversion

Divide by 2 repeatedly. Write the remainders from bottom to top.

Example: Convert decimal 45 to binary
45÷2=22 r1, 22÷2=11 r0, 11÷2=5 r1, 5÷2=2 r1, 2÷2=1 r0, 1÷2=0 r1
Read remainders bottom to top: 101101. Verify: 32+8+4+1 = 45 ✓

Hexadecimal Explained

Hexadecimal uses 16 digits: 0 through 9, then A(10), B(11), C(12), D(13), E(14) and F(15). Each hex digit represents exactly 4 binary bits, making hex much more compact than binary.

HexBinaryDecimal
000000
910019
A101010
F111115
FF11111111255
1A0001101026

Where These Number Systems Are Used

  • Binary (base 2): All digital electronics and computers work in binary internally. Logic gates, memory addresses, network packets and CPU instructions.
  • Decimal (base 10): Everyday human use. Currency, measurements, general maths.
  • Hexadecimal (base 16): Colour codes in web design (#FF5733), memory addresses, MAC addresses, assembly language programming, error codes.
  • Octal (base 8): Used in Unix file permissions (chmod 755). Each octal digit represents 3 binary bits.

Frequently Asked Questions

What is 255 in binary?

The decimal number 255 in binary is 11111111 (eight 1s). This is the maximum value of an 8-bit unsigned integer and corresponds to hexadecimal FF. It appears in networking as the broadcast address in an IPv4 subnet mask (255.255.255.0).

What is hexadecimal used for in web design?

Web colours are expressed as hex codes such as #FF0000 (red), #00FF00 (green) and #0000FF (blue). Each pair of hex digits represents one colour channel (red, green, blue) from 00 (0 intensity) to FF (full intensity).

How do I convert hex to decimal quickly?

Each hex digit is multiplied by 16 to the power of its position (right to left, starting from 0). For example, hex 2B: B=11 at position 0 = 11. Then 2 at position 1 = 2×16 = 32. Total = 32+11 = 43. Use the Hex Converter on CalConvs for any hex to decimal conversion instantly.

Related Tools

Last updated on 6/1/2026