Octal to Binary Converter

Translate base-8 octal numbers into binary bit strings

Convert octal (base-8) numbers to binary (base-2) by expanding each octal digit to its three-bit triplet. Shows trimmed and triplet-aligned views plus a decimal cross-check. Runs entirely in your browser. It runs free in your browser on Gera Tools, with nothing uploaded.

Last updated Source: Gera Tools

How does octal convert to binary?

Because 8 equals 2 cubed, each octal digit corresponds to exactly three binary digits. You expand every octal digit into its three-bit pattern and concatenate the groups.

Converting octal to binary is a direct expansion that is especially useful when reasoning about Unix file permissions or any system that groups bits in threes. This converter turns any base-8 number into its full binary bit string.

How it works

Octal is base 8 and binary is base 2, and 8 equals 2 cubed. That power-of-two relationship means each octal digit maps to a unique group of exactly three binary digits, called a triplet. The conversion is a per-digit lookup — and because only eight triplets exist (one for each value 0–7), the mapping is simple to memorise:

Octal digitBinary triplet
0000
1001
2010
3011
4100
5101
6110
7111

Triplets are joined left to right, preserving digit order. No decimal intermediate is needed. The tool reads each octal character, expands it to its three-bit code, and concatenates. It then shows a trimmed value (leading zeros removed) and a triplet-aligned view that keeps each group intact so the relationship is visible.

Worked example: Unix file permissions

The most common real-world use of octal-to-binary conversion is Unix permission modes. A permission string like chmod 755 encodes nine permission bits — three for the owner, three for the group, and three for everyone else — each bit representing read (r), write (w), or execute (x).

Convert 755:

  • 7111 — owner has read, write, and execute
  • 5101 — group has read and execute, no write
  • 5101 — others have read and execute, no write

Concatenated: 111 101 101, or -rwxr-xr-x in long form. This is the standard mode for an executable script or program.

A mode of 644 works out to 110 100 100 — owner can read and write, but group and others can only read. Typical for regular files.

Another example: converting a larger octal value

Convert octal 0o374. Expanding digit by digit: 3 → 011, 7 → 111, 4 → 100. Concatenated binary is 011111100. Trimming the leading zero: 11111100, which is 252 in decimal.

Tips and notes

  • The triplet-aligned view is ideal for teaching the relationship between bases; always match three-bit groups back to their original octal digit.
  • When a binary result seems wrong, count the triplets — missing a leading zero in a triplet (for example 01 instead of 001 for the digit 1) is the most common hand-calculation error.
  • Spaces, underscores and a leading 0o are accepted and ignored.
  • All processing happens locally in your browser, so nothing you enter is transmitted anywhere.