Chmod Calculator
Unix file permissions use three octal digits for owner, group, and others. Each digit sums read (4), write (2), and execute (1). chmod 755 means rwxr-xr-x: owner has full access, group and others can read and execute. chmod 644 means rw-r--r--: owner reads/writes, others read only. Use 600 for private files, 755 for directories and scripts.
Calculate Unix file permissions with an interactive chmod calculator. Convert between numeric (octal) and symbolic notation. Toggle Owner, Group, Others permissions with checkboxes, use common presets (644, 755, 600, 777), and generate chmod commands. Supports special permissions: setuid, setgid, and sticky bit.
Enter Permissions
Permission Grid
| Entity | Read (4) | Write (2) | Execute (1) | Octal |
|---|---|---|---|---|
| Owner (u) | 7 | |||
| Group (g) | 5 | |||
| Others (o) | 5 |
Special Permissions
Execute as file owner (shows as s in owner execute)
Execute as file group (shows as s in group execute)
Only owner can delete (shows as t in others execute)
Results
Common Presets
Understanding Permissions
Permission Types
Files: View contents. Directories: List files within.
Files: Modify contents. Directories: Create/delete files within.
Files: Run as program. Directories: Access (cd into) the directory.
Entity Types
The user who owns the file. Usually the creator.
Users in the file's group. Used for team collaboration.
Everyone else on the system. The public.
Special Permissions
When set on an executable, it runs with the file owner's privileges. Example: /usr/bin/passwd runs as root.
Files: runs with group privileges. Directories: new files inherit the group.
On directories, only the file owner can delete files. Example: /tmp uses sticky bit.
Common Permission Patterns
| Numeric | Symbolic | Use Case |
|---|---|---|
| 644 | -rw-r--r-- | Regular files (HTML, CSS, images) |
| 755 | -rwxr-xr-x | Executable scripts, directories |
| 600 | -rw------- | SSH private keys, .env files |
| 700 | -rwx------ | Private directories, ~/.ssh |
| 777 | -rwxrwxrwx | Temporary files (use sparingly!) |
| 400 | -r-------- | Read-only sensitive files |
| 444 | -r--r--r-- | Read-only for everyone |
| 666 | -rw-rw-rw- | Shared writable files (no execute) |
| 750 | -rwxr-x--- | Web server directories |
| 775 | -rwxrwxr-x | Shared group directories |
| 640 | -rw-r----- | Config files (owner writes, group reads) |
| 2755 | -rwxr-sr-x | Setgid directories (shared group) |
| 1777 | -rwxrwxrwt | /tmp directory (sticky bit) |
| 4755 | -rwsr-xr-x | Setuid executables (e.g., passwd) |
Click any row to apply that permission.
How to Use
- Enter your value in the input field
- Click the Calculate/Convert button
- Copy the result to your clipboard
Frequently Asked Questions
- What does chmod 755 mean?
- chmod 755 sets permissions to rwxr-xr-x: the owner can read, write, and execute; the group can read and execute; others can read and execute. This is the standard permission for directories and executable scripts. In octal, 7 = rwx (4+2+1), 5 = r-x (4+0+1).
- What is the difference between chmod 644 and 755?
- 644 (rw-r--r--) is for regular files — owner can read/write, everyone else can only read. 755 (rwxr-xr-x) adds execute permission — needed for directories (to cd into them) and scripts/programs. Use 644 for HTML, CSS, images; use 755 for directories and shell scripts.
- How do Unix file permissions work?
- Unix permissions have three sets (owner, group, others) each with three bits: read (4), write (2), execute (1). Add the values for each set to get the octal number. For example, rwx = 4+2+1 = 7, r-x = 4+0+1 = 5. The three digits together form the permission like 755.
- What are setuid, setgid, and sticky bit?
- These are special permissions represented by a leading octal digit. Setuid (4): executable runs as the file owner (e.g., /usr/bin/passwd runs as root). Setgid (2): executable runs as file group, or new files in directory inherit group. Sticky bit (1): only file owner can delete files in directory (e.g., /tmp is 1777).
- What does chmod 600 mean?
- chmod 600 sets permissions to rw------- — only the owner can read and write the file. No one else has any access. This is the recommended permission for sensitive files like SSH private keys (~/.ssh/id_rsa), .env files, and configuration files containing passwords or API keys.
- How do I read symbolic permissions like rwxr-xr-x?
- Symbolic notation has 9 characters in 3 groups of 3. Each group is read (r), write (w), execute (x) or dash (-) for denied. First 3 = owner, middle 3 = group, last 3 = others. rwxr-xr-x means: owner has all permissions, group and others can read and execute but not write.
- Why is chmod 777 considered dangerous?
- chmod 777 gives everyone full read, write, and execute access. Any user on the system can modify or delete the file. This is a security risk, especially for web server files — attackers could inject malicious code. Use the minimum permissions needed: 644 for files, 755 for directories.
Common Unix File Permissions
| Numeric | Symbolic | Use Case |
|---|---|---|
| 644 | rw-r--r-- | Regular files (HTML, CSS, images) |
| 755 | rwxr-xr-x | Directories and executable scripts |
| 600 | rw------- | Private files (SSH keys, .env) |
| 700 | rwx------ | Private directories (~/.ssh) |
| 777 | rwxrwxrwx | Full access (use sparingly) |
| 400 | r-------- | Read-only sensitive files |
| 750 | rwxr-x--- | Web server directories |
Permission Bit Values
| Permission | Symbol | Octal Value |
|---|---|---|
| Read | r | 4 |
| Write | w | 2 |
| Execute | x | 1 |
| No permission | - | 0 |