What is chmod?
chmod stands for "change mode." It's the Unix/Linux command for setting file and directory permissions. Every file has three permission groups — owner, group, and others — and each group can have read (r), write (w), and execute (x) permissions.
Octal vs. symbolic notation
Permissions can be expressed two ways:
- Symbolic:
rwxr-xr--(human-readable) - Octal:
754(compact, used with thechmodcommand)
Each octal digit maps to 3 bits: read=4, write=2, execute=1. Add them together: rwx = 4+2+1 = 7, r-x = 4+0+1 = 5, r-- = 4+0+0 = 4 → 754.
Use the visual chmod Calculator
The chmod Calculator on HTMLToolz lets you toggle checkboxes for each permission bit and instantly see the octal value, symbolic string, and a ready-to-run chmod command.
- Open htmltoolz.com/tools/chmod-calculator
- Check or uncheck the Read / Write / Execute boxes for Owner, Group, and Others
- Copy the octal code or the full
chmod 755 filenamecommand
Common permission patterns
| Octal | Symbolic | Typical use |
|---|---|---|
| 755 | rwxr-xr-x | Executable scripts, directories |
| 644 | rw-r--r-- | Web files (HTML, CSS, PHP) |
| 600 | rw------- | SSH keys, secret files |
| 777 | rwxrwxrwx | World-writable (avoid in production) |
| 400 | r-------- | Read-only private key |
Recursive chmod
To apply permissions to a directory and everything inside it, use the -R flag:
chmod -R 755 /var/www/html
Be careful with recursive chmod — setting execute on files that should not be executable (like PHP files) can be a security risk. The common pattern for web roots is to set directories to 755 and files to 644:
find /var/www/html -type d -exec chmod 755 {} \;
find /var/www/html -type f -exec chmod 644 {} \;
Related tools
- HTAccess Generator — build Apache rewrite rules
- IP / CIDR Calculator — subnet and network address calculator



