Skip to content
BetterDL

Octal–decimal conversion

Also called: octal to decimal, decimal to octal

Converting between octal and decimal: multiply each octal digit by its power of 8 and add, or divide by 8 repeatedly to go the other way.

Octal → decimal: digit × weight, then add. Octal weights are powers of 8: 1, 8, 64, 512, 4096.

Decimal → octal: repeated division by 8. Each remainder (0 to 7) is one octal digit, starting from the right, so read them last to first.

You can also go through binary: convert to binary, then group the bits in threes from the right (binary octal conversion). That route is handy when you already have the binary, or need hex as well.

A quick sanity check: an octal number never contains 8 or 9. If a remainder comes out as 8 or more, you divided by the wrong number.

1
128
1
64
1
32
0
16
0
8
1
4
1
2
1
1

Worked examples

Example

347₈ to decimal

Multiply by powers of 8.

  1. 1.

    3 × 64 = 192.

  2. 2.

    4 × 8 = 32.

  3. 3.

    7 × 1 = 7.

  4. 4.

    Total: 231. Through binary: 011 100 111 = 11100111₂ = 128 + 64 + 32 + 4 + 2 + 1 = 231.

Example

500₁₀ to octal

Divide by 8 until the quotient is 0.

  1. 1.

    500 ÷ 8 = 62 remainder 4.

  2. 2.

    62 ÷ 8 = 7 remainder 6.

  3. 3.

    7 ÷ 8 = 0 remainder 7.

  4. 4.

    Read last to first: 764₈. Check: 7 × 64 + 6 × 8 + 4 = 448 + 48 + 4 = 500.

Common mistakes

  • Using powers of 10 as the weights.

  • Reading the remainders top-down.

  • Ending up with a digit 8 or 9, which can't appear in octal.

Practice Octal–decimal conversion

Interactive questions with instant feedback and a worked solution for every wrong answer.

Learn it step by step

Octal–decimal conversion is taught in Number Systems.