chmod calculator
Unix file permissions: octal, rwx and chmod commands.
| Who | Read | Write | Execute |
|---|---|---|---|
| Owner | |||
| Group | |||
| Others |
Try
Results
- Octal
- 755or 0755
- Symbolic
- rwxr-xr-x
- ls -l
- -rwxr-xr-x
- Command
- chmod 755 file
- Symbolic command
- chmod u=rwx,g=rx,o=rx file
In words
- Owner: read, write and run
- Group: read and run
- Others: read and run
About this tool
- Runs in
- your browser
- Your input sent to our servers
- Nothing
- Kept on this device
- nothing
More in the privacy policy.
How to use it
- 01Type an octal mode such as 755, a symbolic one such as rwxr-xr-x (an ls -l line works too), or tick the boxes. Or pick one under Try.
- 02The other forms update as you go: octal, symbolic, the chmod commands and the permissions in words.
- 03Tick Recursive for a folder and its contents, then copy the command.
Related tools
Questions
What do the numbers mean?
Each digit is one class: owner, group, then others. Read counts 4, write 2 and execute 1, added up: 7 is all three, 5 is read and execute, 4 is read only. So 755 is rwxr-xr-x: the owner can do everything, everyone else can read and run.
What does execute mean for a folder?
For a file, execute lets it run as a program. For a folder it lets you enter the folder and reach the files inside; read lets you list their names. A folder usually needs both, which is why folders are 755 and plain files 644.
What are setuid, setgid and sticky?
A fourth digit in front. Setuid (4) makes a program run as its owner, whoever starts it; setgid (2) runs it as its group, and in a folder gives new files the folder’s group; sticky (1), on a shared folder such as /tmp (1777), stops people deleting each other’s files. In symbolic form they show as s or t in the execute place: 4755 is rwsr-xr-x; a capital S or T means the bit is set without execute.
Is 777 safe?
It gives everyone every permission (others can read, write and run), so any user or process on the machine can change or replace the file. It’s rarely needed; for a folder that several people share, 1777 or a shared group with 775 is the usual answer.
What about chmod +x or u+x?
Those change permissions relative to the file’s current ones, which this page can’t see. Start from the mode the file has now (ls -l shows it, and you can paste that line here), tick what you want, and use the command it gives.
Is anything sent anywhere?
No. It’s worked out in your browser. Nothing is sent to our servers, put into the page address or saved.