Tools / Chmod Calculator

Chmod Calculator

Convert between rwx checkboxes, octal (755), and symbolic (rwxr-xr-x) permissions — all three update live, entirely in your browser. Nothing is sent anywhere.

755 — owner can read, write, and execute; group and others can read and execute.

Presets
readwriteexecute
owner
group
other
chmod 755 <file>

About

Unix file permissions are stored as a handful of bits, not a lookup table. Every file and directory tracks three subjects — its owner, its group, and everyone else — and three abilities per subject: read (4), write (2), and execute (1). Add the abilities you want for a subject and you get a single digit from 0 through 7: 7 (4+2+1) is full access, 5 (4+1) is read and execute with no write, 6 (4+2) is read and write with no execute, and 0 is nothing at all. String three of those digits together, one per subject, and you have the octal mode chmod expects. 755 means the owner is 7 (rwx), and the group and everyone else are each 5 (r-x) — they can read and run the file, but not modify it. 644 is the common file default: the owner can read and write, everyone else can only read.

A fourth, leading digit adds three more bits sitting ahead of the usual nine: setuid, setgid, and the sticky bit. Unlike the read/write/execute bits, these don’t add a tenth character to the symbolic string — they overwrite the execute character in the owner, group, or other triad, which is exactly where most chmod calculators get sloppy. This tool’s checkboxes, octal field, and symbolic field stay in sync no matter which one you edit, so you can move between the format you’re thinking in and the format your terminal is showing you without doing the arithmetic by hand. Paste a full ls -l listing straight in — the leading file-type character and any trailing SELinux or ACL marker are stripped automatically.

FAQ

What do setuid, setgid, and the sticky bit actually do?
Setuid (4000) makes an executable run with its owner’s privileges instead of the caller’s — classic example: /usr/bin/passwd runs as root so an ordinary user can edit a root-owned password file. Setgid (2000) does the same for the group; on a directory, it also makes new files inherit that directory’s group instead of the creating user’s default group. The sticky bit (1000) on a directory restricts deleting or renaming files inside it to each file’s owner — plus the directory’s owner and root — even when the directory itself is world-writable; /tmp is the standard example.
Why does ls show a capital S or T sometimes?
ls represents setuid, setgid, and the sticky bit by overwriting the execute character in the owner, group, or other triad — it doesn’t add a tenth character. If the underlying execute bit for that subject is also on, you get a lowercase letter (s or t): 4755 is rwsr-xr-x. If execute is off for that subject, the letter is uppercase and means "this special bit is set, but the file isn’t executable by that subject" — 4655 is rwSr-xr-x, and 1776 is rwxrwxrwT. The uppercase form is usually a sign something is misconfigured, since setuid/setgid only matter on executables.
What’s the difference between 755 and 775?
755 gives the group the same access as everyone else — read and execute, no write. 775 adds write access for the group, so any member of the file’s group can modify it while outsiders still can’t. Use 775 for files a team collaborates on directly (shared scripts, a group-owned working directory); use 755 — the more common default for executables and directories — when the group shouldn’t be able to change the file, only run or read it.

Related