Decimal to Octal Converter

Convert base-10 numbers to base-8 and back, with the division steps shown so you can check the result by hand.

Octal (base 8)
Enter a decimal number.

How it was calculated

Digits 0–7 only.

Decimal (base 10)
Enter an octal number.

How the conversion works

Octal is base 8, so each position represents a power of 8. To convert from decimal, divide by 8 repeatedly and collect the remainders:

Worked example. Convert 100 to octal:

Reading the remainders from the bottom up gives 144. Checking the other way:

1×8² + 4×8¹ + 4×8⁰ = 64 + 32 + 4 = 100

Common values

DecimalOctalWhere you see it
00Zero
810Base rollover
641008²
100144Worked example
255377Maximum 8-bit value
420644Common Unix file permission
493755Common Unix file permission
511777Full permissions
40957777Maximum 12-bit value

Frequently asked questions

How do you convert decimal to octal by hand?
Repeatedly divide the number by 8 and keep each remainder. Read the remainders from last to first. For 100: 100/8 = 12 remainder 4, 12/8 = 1 remainder 4, 1/8 = 0 remainder 1, giving 144 in octal.
Why is octal used in computing?
Octal groups binary neatly into sets of three bits, which made it a compact way to read binary on early computers. It is still most visible today in Unix file permissions, where values such as 755 encode read, write and execute rights.
Can this tool handle negative numbers?
Yes. The sign is preserved and applied to the converted value, so −100 decimal becomes −144 octal.
What about numbers too large for JavaScript?
Values beyond about 15 digits lose precision because JavaScript numbers are double-precision floats. For everyday use this is not a problem, but for cryptographic-size integers use a big-integer library instead.
Is my data uploaded anywhere?
No. The conversion runs entirely in your browser; nothing is sent to a server.

Related tools

Last updated: August 31, 2026