Octal (Base 8) to Binary (Base 2) Converter

Convert octal numbers to binary.

11111111

377 (base 8) = 11111111 (base 2)

Digits in base 8: 0 to 7. Digits in base 2: 0 and 1.

How to convert Octal to Binary

Every positional number system works the same way: a digit is worth its own value times the base raised to the power of its position. In base 8 the place values, from the right, are 80 = 1, 81 = 8, 82 = 64 and so on.

Most pairs have no direct trick, so go through decimal, the base we all calculate in. First turn the base 8 number into decimal, then divide by 2 and read the remainders from the bottom up. Two short steps, and you can check the number in the middle.

Because 8 is a power of 2, there is a faster way that skips decimal. Each base 8 digit is exactly 3 bits, so replace every digit with its 3-bit pattern and you are done.

The method

decimal value = each digit × its place value, all added upplace values in base 8: 1, 8, 64, 512, 4096, and so ondivide by 2, keep the remainder, repeat until the quotient is 0the answer is the remainders read from last to first1 base 8 digit = 3 bitsdigits in base 8: 0 to 7digits in base 2: 0 and 1

Worked example 1: 55 from octal to binary

Step 1: base 8 to decimal55 (base 8) = 5 × 81 + 5 × 80= 40 + 5= 45Step 2: decimal to base 245 ÷ 2 = 22 remainder 122 ÷ 2 = 11 remainder 011 ÷ 2 = 5 remainder 15 ÷ 2 = 2 remainder 12 ÷ 2 = 1 remainder 01 ÷ 2 = 0 remainder 1Read the remainders from the bottom up: 10110155 (base 8) = 101101 (base 2)

Remainders come out last digit first, which is why you read them from the bottom up. Digits that are 0 add nothing to the sum, so they are left out of the expansion.

Worked example 2: 377 from octal to binary

Step 1: base 8 to decimal377 (base 8) = 3 × 82 + 7 × 81 + 7 × 80= 192 + 56 + 7= 255Step 2: decimal to base 2255 ÷ 2 = 127 remainder 1127 ÷ 2 = 63 remainder 163 ÷ 2 = 31 remainder 131 ÷ 2 = 15 remainder 115 ÷ 2 = 7 remainder 17 ÷ 2 = 3 remainder 13 ÷ 2 = 1 remainder 11 ÷ 2 = 0 remainder 1Read the remainders from the bottom up: 11111111377 (base 8) = 11111111 (base 2)

Worked example 3: 1750 from octal to binary

Step 1: base 8 to decimal1750 (base 8) = 1 × 83 + 7 × 82 + 5 × 81= 512 + 448 + 40= 1,000Step 2: decimal to base 21,000 ÷ 2 = 500 remainder 0500 ÷ 2 = 250 remainder 0250 ÷ 2 = 125 remainder 0125 ÷ 2 = 62 remainder 162 ÷ 2 = 31 remainder 031 ÷ 2 = 15 remainder 115 ÷ 2 = 7 remainder 17 ÷ 2 = 3 remainder 13 ÷ 2 = 1 remainder 11 ÷ 2 = 0 remainder 1Read the remainders from the bottom up: 11111010001750 (base 8) = 1111101000 (base 2)

Worked example 4: 265 with the bit-group shortcut

265 (base 8)Write each digit as 3 bits: 2 = 010, 6 = 110, 5 = 101Join them and drop leading zeros: 10110101265 (base 8) = 10110101 (base 2)

Both bases are powers of 2, so there is no need to go through decimal.

Need the other direction? Open the Binary to Octal converter.

Octal to Binary examples

The decimal number 255 is written 377 in octal and 11111111 in binary.

Common Octal to Binary values
OctalBinaryDecimal
111
2102
71117
1010008
12101010
17111115
201000016
4010000032
100100000064
1441100100100
37711111111255
175011111010001000

Where Octal to Binary comes up

Octal uses the digits 0 to 7, and each octal digit stands for exactly three bits. Unix file permissions such as chmod 755 are written in octal, and it also appears in older machine listings where word sizes divide by three.

Binary uses only 0 and 1, because a digital circuit has two stable states: off and on. Every number a computer stores is binary underneath. You meet it when you work with bit flags, bit masks, subnet masks and low-level debugging.

Going to a smaller base spreads the same value over more digits, so the result is longer. The number 255 needs 3 digits in octal and 8 in binary.

Octal to Binary FAQ

How do I convert octal to binary?

Convert to decimal first by adding up each digit times its place value, then divide that decimal number by 2 repeatedly and read the remainders from last to first. Because both bases are powers of 2, you can also skip decimal and work with groups of bits.

Which digits does octal use?

Base 8 uses the digits 0 to 7. For example, 8 is not a valid digit in base 8.

Will the binary number be longer or shorter?

Longer. Going to a smaller base spreads the same value over more digits, so the result is longer. Roughly 3 binary digits for every octal digit. The number 255 needs 3 digits in octal and 8 in binary.

Is there a shortcut for octal to binary?

Yes. Because 8 is a power of 2, there is a faster way that skips decimal. Each base 8 digit is exactly 3 bits, so replace every digit with its 3-bit pattern and you are done.

Can I convert negative numbers or fractions?

The converter handles whole numbers, and a leading minus sign works for negatives. Fractions use a different method, where you repeatedly multiply the fractional part by the new base, and they are not supported here.