Chmod Calculator
Convert Unix file permissions between checkbox, octal (755) and symbolic (rwxr-xr-x). Handles setuid, setgid and the sticky bit, with a ready chmod command.
| Who | Read | Write | Execute | Octal |
|---|---|---|---|---|
| Owner (u) | 6 | |||
| Group (g) | 4 | |||
| Others (o) | 4 |
Octal
Symbolic
rw-r--r--
Command
chmod 644 fileTick boxes or type an octal value (3 or 4 digits) — both stay in sync. The 4th leading digit encodes setuid/setgid/sticky.
How Unix permissions work
Every file has three permission sets — for the owner, the group, and everyone else — and each set has three bits: read (4), write (2) and execute (1). Add the bits per set to get one octal digit, giving the familiar three-digit number like 755 = rwx r-x r-x.
Common values
| Octal | Symbolic | Typical use |
|---|---|---|
| 644 | rw-r--r-- | Normal files |
| 755 | rwxr-xr-x | Scripts, directories, binaries |
| 600 | rw------- | Private files (keys, .env) |
| 700 | rwx------ | Private directories |
| 777 | rwxrwxrwx | World-writable (avoid!) |
| 775 | rwxrwxr-x | Group-shared directories |
The special bits
- setuid (4xxx): an executable runs with the file owner's privileges (e.g.
passwd). Powerful — use sparingly. - setgid (2xxx): on a directory, new files inherit its group — great for shared project folders.
- sticky (1xxx): in a shared directory like
/tmp, only a file's owner can delete it. Shows astin the “other” execute slot.
Octal vs symbolic chmod
chmod 755 file sets permissions absolutely. Symbolic form changes them relatively: chmod u+x file adds execute for the owner only, chmod go-w file removes write for group and others. Use octal when you want an exact known state, symbolic for surgical tweaks. Directories almost always need the execute bit to be enterable, even though it isn't “running” anything.