File Permission (chmod) Calculator
Work out file permission (chmod) instantly with clear inputs, formula shown and shareable results.
About File Permission (chmod) Calculator
Unix permissions encode read as 4, write as 2 and execute as 1, summed per class of user. Owner, group and other each get one octal digit, so 750 means rwx for the owner, r-x for the group and nothing for everyone else. The execute bit means something different on directories: it grants the right to traverse into them rather than to run them.
Formula
Permission arithmetic
digit = 4 (read) + 2 (write) + 1 (execute) per class; mode = owner digit, group digit, other digit
Worked example
With the default values below, File Permission (chmod) Calculator returns Octal mode of 750. Change any input above and every figure here is recalculated in your browser.
Inputs used
- Owner permissionsone of --- (0), r-- (4), rw- (6), rwx (7), r-x (5)
- rwx (7)
- Group permissionsone of --- (0), r-- (4), rw- (6), rwx (7), r-x (5)
- r-x (5)
- Other permissionsone of --- (0), r-- (4), rw- (6), rwx (7), r-x (5)
- --- (0)
Results
- Octal mode
- 750
- Symbolic mode
- rwxr-x---
- Command
- chmod 750 <path>
- Security note
- No access for other users
Step by step
- 1Values used
- 2Permission arithmetic
- 3Octal mode= 750
- 4Symbolic mode= rwxr-x---
- 5Command= chmod 750 <path>
- 6Security note= No access for other users
Assumptions and limits
- The result is derived only from the 3 inputs listed above. Anything not among them is not part of the calculation.
- In particular, this calculator does not take inflation, tax, fees or charges or compounding frequency into account.
How these calculators are built and tested is described on the Methodology page. If a figure looks wrong, please report it.
Frequently Asked Questions
Why does a directory need the execute bit?
On a directory, execute means traverse. Without it you cannot access anything inside even if you can list the names, because listing needs read and entering needs execute.
What is wrong with 777?
It lets any local user or compromised process modify the file. It is almost never necessary; the correct fix is usually to set the right owner or group.
Related Calculators
- Octal Permission Converter Calculator
- Open File Limit Calculator
- Ulimit File Descriptors Calculator
- Account Lockout Policy Calculator
- Backup Size With Retention Calculator
- Bare Metal Sizing Calculator
- Bash Script Runtime Calculator
- Block Size Overhead Calculator
- Compression Ratio Savings Calculator
- Container vs VM Overhead Calculator
You might also need
- Octal Permission Converter CalculatorAlso in Linux & System Administration
- Open File Limit CalculatorAlso in Linux & System Administration
- Ulimit File Descriptors CalculatorAlso in Linux & System Administration
- Container vs VM Overhead CalculatorAlso in Linux & System Administration
- CPU Utilisation CalculatorAlso in Linux & System Administration
- Free Memory Estimate CalculatorAlso in Linux & System Administration
