Skip to content

Octal to Decimal Converter

Paste octal numbers such as 755 or 0o777 and get their exact decimal value, optionally read as a signed two’s-complement pattern.

Processed locally in your browser

Options

Signed reads the top bit as the sign (two’s complement). Shorter inputs are zero-extended to the chosen width.

One number per line. Spaces and underscores inside a number are ignored.0 chars · 0 lines
The result will appear here.

What is Octal to Decimal Converter?

Octal is the base-8 numeral system: it uses the digits 0 to 7, and every digit stands for exactly three bits. That made it popular on early computers and it survives today in Unix file permissions (chmod 755), in escape sequences such as \033 and in the 0o prefix of Python, JavaScript and Rust.

The converter reads each line as an octal integer, ignoring spaces, underscores and an optional 0o prefix or leading minus. It uses arbitrary-precision arithmetic, so very long values stay exact. You can also treat the digits as a bit pattern of a signed 8, 16, 32 or 64-bit integer, and add thousands separators to the result.

How does it work?

  1. Enter one octal number per line, for example 755, 0o777 or 377.
  2. Optionally choose a signed width so that a pattern like 377 is read as −1 in 8 bits.
  3. Choose a thousands separator if you want a readable decimal result.
  4. Read the decimal output; for one number the rows also show binary, hexadecimal and the byte size.

Common use cases

  • Turning a chmod mode such as 644 or 755 into its decimal value for a script or an API that expects a number.
  • Decoding an octal escape or the size field of a tar header while reading a binary format.
  • Checking a Python or C constant like 0o1777 against its decimal value.
  • Homework and exam practice on converting between number bases.

Examples

Try this input in the tool above:

Input
755
0o777
377
7777777777777777777777
Output
493
511
255
73786976294838206463

Privacy

Octal to Decimal Converter runs entirely in your browser. The text or files you provide are processed on your device and are not uploaded, logged or stored on our servers.

Limitations

Only whole numbers are supported here (use the Base Converter for fractions). Digits 8 and 9 are not valid in octal and are reported as errors.

Frequently asked questions

What is 755 in decimal?

755 in octal equals 493 in decimal: 7×64 + 5×8 + 5. It is the classic “rwxr-xr-x” permission mode.

Why is the digit 8 rejected?

Octal has only eight digits, 0 to 7. A digit 8 or 9 means the number is not octal, so the line is flagged instead of guessed.

How do I read a negative octal number?

Either type a minus sign before the digits, or pick a signed width: 377 read as signed 8-bit gives −1 because its top bit is set.

More tools in Developer Tools →