Octal is base 8. Digits 0 through 7. If you have used chmod 755, you have used octal.
Convert octal to binary, decimal, and hex instantly.
Open Converter →| Octal | Binary | Decimal |
|---|---|---|
| 0 | 000 | 0 |
| 1 | 001 | 1 |
| 2 | 010 | 2 |
| 3 | 011 | 3 |
| 4 | 100 | 4 |
| 5 | 101 | 5 |
| 6 | 110 | 6 |
| 7 | 111 | 7 |
Octal 752: 7→111, 5→101, 2→010 = 111101010 (490 decimal).
Octal 752: 7×64 + 5×8 + 2×1 = 448 + 40 + 2 = 490
490: 490÷8=61r2, 61÷8=7r5, 7÷8=0r7. Read bottom to top: 752.
| Permission | Bit | Meaning |
|---|---|---|
| r (read) | 4 | View contents |
| w (write) | 2 | Modify |
| x (execute) | 1 | Run or enter directory |
Common permissions:
| Octal | Binary | Symbolic | Meaning |
|---|---|---|---|
| 755 | 111 101 101 | rwxr-xr-x | Owner full. Group/others read+execute. |
| 644 | 110 100 100 | rw-r--r-- | Owner read/write. Others read only. |
| 700 | 111 000 000 | rwx------ | Owner only. |
| 777 | 111 111 111 | rwxrwxrwx | Full access for everyone. Avoid this. |
| 600 | 110 000 000 | rw------- | Owner read/write. Good for SSH keys. |
int x = 010; is octal 10 = decimal 8, not 10int y = 0755; = decimal 493int z = 099; = compiler error (9 invalid in octal)Go through binary: 752 → 111 101 010 → regroup: 0001 1110 1010 → 1EA hex.
Related: Base64 Encoder, JSON Formatter.