Octal converter
Convert text to octal (base-8) codes and octal back to readable text. Useful for programming, Unix permissions study and puzzles. Free converter.
Convert between text and octal numbers
Octal is the base-8 number system, using only the digits 0–7. Each octal digit stands for exactly three bits, which made it popular in early computing. The letter A (decimal 65) is 101 in octal, and "Hi" is 110 151.
Choose To octal to turn text into octal codes or To text to convert octal back to characters.
You'll still meet octal in Unix and Linux file permissions (like chmod 755), escape sequences in C, Python and shell scripts (such as \101), and computer science courses.
How to use the octal converter
- Paste text or octal codes.
- Choose To octal or To text.
- Submit to convert.
- Copy the result.
Examples
Text to octal
Input: Hi
Output: 110 151
H is 72 in decimal: 1×64 + 1×8 + 0 = 110 in octal.
A single letter
Input: A
Output: 101
Octal to text
Input: 110 151 41
Output: Hi!
41 in octal is 33 in decimal, the exclamation mark.
An accented letter
Input: é
Output: 303 251
Two UTF-8 bytes, two octal numbers.
Common uses
- Decoding octal escape sequences in code and logs.
- Number-system homework and exercises.
- Puzzles and coded messages.
- Understanding legacy systems that use octal.
- Learning how number systems work alongside binary and hex.
- Decoding octal escape sequences such as \110\151, which still appear in C strings, shell scripts and some log files.
- Making simple coded messages for puzzles.
Tips and things to know
- Separate each code with a space when converting to text.
- In Unix permissions, each digit is a sum of read (4), write (2) and execute (1), so 7 = rwx and 5 = r-x.
- Compare the same text in other bases with the binary, decimal and hex converters.
Edge cases and limitations
- The digits 8 and 9 don't exist in octal and are ignored, so
189is read as octal 1 and gives an invisible control character instead of an error. - Separate codes with single spaces. A double space or trailing space adds an invisible NUL character.
- Unix permissions like 755 are three separate digits (owner, group, others), not a character code, so converting them to text gives nothing useful.
- The output has a trailing space after the last code.
- Octal numbers above 377 (255 in decimal) don't fit in one byte and give unexpected characters.
Frequently asked questions
What is octal used for today?
Mainly Unix file permissions and escape sequences in programming languages.
Why are there no 8s or 9s in octal?
Base 8 only uses digits 0 to 7; after 7 comes 10.
What is "A" in octal?
101.
Is octal the same as decimal?
No. Octal 10 equals decimal 8.
How do I read an octal escape like \303\251?
Enter the numbers without the backslashes, separated by spaces: 303 251. They decode to é, which is two bytes in UTF-8.
How do I convert octal to decimal by hand?
Multiply each digit by a power of 8, starting from the right: 151 is 1×64 + 5×8 + 1 = 105, the letter i.
Related tools
- Binary converter: Convert text to binary and the other way for any string input.
- Decimal converter: Convert text to decimal and the other way for any string input.
- Hex converter: Convert text to hexadecimal and the other way for any string input.
- Ascii converter: Convert text to ascii and the other way for any string input.
- Roman Numerals to Number: Convert roman numerals to a number with ease.
Similar tools
Convert text to binary code (Hi = 1001000 1101001) and binary back to text. Learn how computers store characters. Free online binary translator.
Convert text to hexadecimal (hex) code and hex back to readable text. Handy for debugging, encoding and learning. Free online text to hex converter.
Convert text to ASCII character codes and ASCII codes back to text. Look up the number behind every letter and symbol. Free online ASCII converter.
Popular free tools
Create strong, random passwords in one click. Pick the length and include uppercase, lowercase, numbers and symbols. Free, no signup.
Extract every email address from text, HTML, logs or documents in one click and get a clean list with a count. Free online email extractor.
Convert text to UPPERCASE, lowercase, Sentence case, Capital Case, camelCase, PascalCase, snake_case, CONSTANT_CASE, dot.case or param-case. Free.
Look up the DNS records of any domain: A, AAAA, CNAME, MX, NS, TXT and SOA. Check email, SPF, verification and nameserver settings for free.
Create a WhatsApp click-to-chat link with your phone number and a prefilled message. Add it to your site, bio, ads or QR codes. Free wa.me generator.
Enter an IP address to find the host name or domain associated with it through a reverse DNS (PTR) lookup. Free reverse IP lookup tool.