# Chmod Calculator

Convert Linux file permissions between octal (755) and symbolic (rwxr-xr-x) form. Each digit is a sum — read 4, write 2, execute 1 — for the owner, the group and everyone else; an optional leading digit sets setuid (4), setgid (2) and the sticky bit (1).

## Common modes

- [chmod 777 (rwxrwxrwx)](https://www.devkult.com/chmod/777.md): Everyone can read, write and execute
- [chmod 775 (rwxrwxr-x)](https://www.devkult.com/chmod/775.md): Owner and group can do everything; others can read and execute
- [chmod 770 (rwxrwx---)](https://www.devkult.com/chmod/770.md): Owner and group can do everything; everyone else has no access
- [chmod 755 (rwxr-xr-x)](https://www.devkult.com/chmod/755.md): Owner can do everything; group and others can read and execute
- [chmod 750 (rwxr-x---)](https://www.devkult.com/chmod/750.md): Owner can do everything; group can read and execute; others have no access
- [chmod 711 (rwx--x--x)](https://www.devkult.com/chmod/711.md): Owner can do everything; others can only pass through
- [chmod 700 (rwx------)](https://www.devkult.com/chmod/700.md): Only the owner can read, write and execute
- [chmod 666 (rw-rw-rw-)](https://www.devkult.com/chmod/666.md): Everyone can read and write; nobody can execute
- [chmod 664 (rw-rw-r--)](https://www.devkult.com/chmod/664.md): Owner and group can read and write; others can read
- [chmod 660 (rw-rw----)](https://www.devkult.com/chmod/660.md): Owner and group can read and write; others have no access
- [chmod 644 (rw-r--r--)](https://www.devkult.com/chmod/644.md): Owner can read and write; everyone else can read
- [chmod 640 (rw-r-----)](https://www.devkult.com/chmod/640.md): Owner can read and write; group can read; others have no access
- [chmod 600 (rw-------)](https://www.devkult.com/chmod/600.md): Only the owner can read and write
- [chmod 444 (r--r--r--)](https://www.devkult.com/chmod/444.md): Everyone can read; nobody can write or execute
- [chmod 400 (r--------)](https://www.devkult.com/chmod/400.md): Only the owner can read; nobody can write or execute
- [chmod 4755 (rwsr-xr-x)](https://www.devkult.com/chmod/4755.md): 755 plus setuid: the program runs with its owner's privileges
- [chmod 2775 (rwxrwsr-x)](https://www.devkult.com/chmod/2775.md): 775 plus setgid: new files inherit the directory's group
- [chmod 1777 (rwxrwxrwt)](https://www.devkult.com/chmod/1777.md): 777 plus the sticky bit: anyone can create, only owners can delete

## FAQ

### What does chmod do?

chmod (change mode) sets who can read, write and execute a file or directory. Permissions are set separately for the file's owner, its group, and everyone else.

### What's the difference between chmod and chown?

chmod changes what each class of user may do; chown changes who the owner and group are. Many 'Permission denied' errors are really ownership problems — fix them with chown rather than loosening permissions.

### How do I see a file's current permissions?

Run `ls -l file` to see the symbolic form (like `-rw-r--r--`), or `stat -c '%a %A %n' file` on Linux (`stat -f '%Lp %Sp %N' file` on macOS) to get the octal number too.

### Is 0755 different from 755?

No. The optional leading digit holds the special bits (setuid, setgid, sticky); 0 means none are set, so 0755 and 755 are the same mode.

### What does chmod +x do?

It adds execute permission. With no u, g or o in front, chmod applies it to all three classes, except where your umask masks it — so `chmod +x script.sh` usually gives rwxr-xr-x to a 644 file. Use `chmod u+x` to add it for the owner only.

Open the interactive calculator: https://www.devkult.com/chmod