FT
Digital

Binary, Hexadecimal, and Number Systems: A Beginner's Guide

Learn how different number systems work, why computers use binary, and how to convert between bases.

Number systems are the foundation of computing. While we use the decimal system (base 10) in daily life, computers work in binary (base 2), and programmers frequently use hexadecimal (base 16). Understanding these systems helps you work with computers at a deeper level.

Decimal (Base 10)

The decimal system uses ten digits: 0-9. Each position represents a power of 10. The number 352 means 3×100 + 5×10 + 2×1.

Binary (Base 2)

Computers use binary because electronic circuits have two states: on (1) and off (0). Each binary digit (bit) represents a power of 2.

Binary 1010 means: 1×8 + 0×4 + 1×2 + 0×1 = 10 in decimal.

Common binary values to remember:

  • 8 bits (1 byte) can represent values 0-255
  • 16 bits can represent values 0-65,535
  • 32 bits can represent values 0-4,294,967,295

Hexadecimal (Base 16)

Hexadecimal uses 16 digits: 0-9 and A-F (where A=10, B=11, C=12, D=13, E=14, F=15). It is a compact way to represent binary data since each hex digit represents exactly 4 binary digits.

Common uses of hexadecimal:

  • Web colors: #FF0000 (red), #00FF00 (green), #0000FF (blue)
  • Memory addresses: 0x7FFF5FBFF8A0
  • Unicode characters: U+1F600 (😀)
  • MAC addresses: A1:B2:C3:D4:E5:F6

Octal (Base 8)

Octal uses digits 0-7. It was historically important in computing and is still used in Unix/Linux file permissions (chmod 755 means rwxr-xr-x).

Quick Reference Table

DecimalBinaryOctalHex
0000000
5010155
10101012A
15111117F
16100002010
25511111111377FF
binaryhexadecimalcomputingprogramming

Need to convert units?

Try our free online converters for instant, accurate results.