Chmod Calculator
Calculate Unix file permission values visually. Toggle read, write and execute for owner, group and others — get the octal value and symbolic string instantly.
Understanding Unix File Permissions
Unix and Linux systems control file access with three permission sets — Owner (the file creator), Group (users in the assigned group) and Others (everyone else). Each set has three bits: Read (4), Write (2) and Execute (1). Adding the bits gives the octal digit for that set.
Common Permission Values
| Octal | Symbolic | Typical use |
|---|---|---|
| 755 | rwxr-xr-x | Web-accessible directories, scripts |
| 644 | rw-r--r-- | Regular files, HTML, CSS |
| 600 | rw------- | Private files, SSH keys |
| 700 | rwx------ | Private directories |
| 777 | rwxrwxrwx | Fully open (avoid in production) |
| 664 | rw-rw-r-- | Shared group-editable files |
Execute Bit on Directories
For directories, the execute bit means traversal — the ability to enter the directory and access files inside it. A directory with r-- (read but no execute) lets you list its contents but blocks access to any file within it. This is why directories typically carry permissions like 755 or 700 while regular files use 644 or 600.
chmod Command Syntax and Examples
| Command | What it does |
|---|---|
chmod 644 file.txt | Owner read/write; Group and Others read-only |
chmod 755 script.sh | Owner full access; Group and Others read+execute |
chmod 600 ~/.ssh/id_rsa | Owner read/write only — required for SSH private keys |
chmod -R 755 /var/www/ | Apply 755 recursively to all files and directories |
chmod +x deploy.sh | Add execute for all entities (symbolic mode) |
chmod go-w sensitive/ | Remove write from Group and Others (symbolic mode) |