Chmod Calculator — Unix File Permissions
Convert Linux file permissions between octal form such as 755 and symbolic form such as rwxr-xr-x, using r=4, w=2, x=1 for owner, group, and others.
Chmod Calculator — Unix File Permissions
Calculator
Adjust values & calculateEnter your values below. Every result is computed in your browser — no data is sent to any server.
Formula: r=4, w=2, x=1 | Owner-Group-Others
Worked example — rwxr-xr-x
Formula
r=4, w=2, x=1 | Owner-Group-Others
Convert between symbolic (rwxr-xr-x) and octal (755) Linux file permissions.
Worked Examples
Example 1: chmod 755
Problem:Octal 755
Solution:rwxr-xr-x: Owner all, Group/Others read+execute
Result:rwxr-xr-x
Frequently Asked Questions
What does chmod 777 mean?
Full permissions (read+write+execute) for everyone. Generally dangerous — use 755 for directories and 644 for files as defaults.
How are octal permission digits calculated?
Each digit sums the values: read=4, write=2, execute=1. So 7=rwx, 6=rw-, 5=r-x, 4=r--. The three digits represent Owner, Group, and Others respectively.
What is the difference between 755 and 644?
chmod 755 (rwxr-xr-x) is standard for directories and executables — owner can write, everyone can read and traverse. chmod 644 (rw-r--r--) is standard for regular files — owner can write, everyone else can only read.
When would I use the execute bit on a file?
The execute bit is required to run scripts and compiled programs. Set it with chmod +x on shell scripts, Python files with a shebang line, or any binary. Without it, the OS refuses to run the file directly.
How does umask decide the permissions of a new file?
The umask is a mask of bits to withhold, not bits to grant. The kernel starts from 666 for a regular file and 777 for a directory, then clears whatever the umask sets. The common umask of 022 therefore yields 644 for files and 755 for directories, while a stricter 077 gives 600 and 700 and keeps everything private to the owner. Regular files never receive the execute bit at creation, which is why a new script needs chmod +x before it will run.
What do the setuid, setgid and sticky bits do?
They live in the optional fourth octal digit. Setuid, 4000, runs an executable with the identity of the file owner rather than the caller, which is how passwd can edit a root-owned file. Setgid, 2000, does the same for the group and, on a directory, makes new entries inherit that directory group instead of the creator primary group, the standard arrangement for shared project folders. The sticky bit, 1000, on a world-writable directory such as /tmp lets only the owner of an entry delete it.
What does the execute bit mean on a directory?
On a directory, execute is search or traverse permission: the right to enter it and reach a named entry inside. Read is what lists the names. The two are independent, so a directory with r-- lets you see filenames but not open them or read their metadata, while --x lets you open a path you already know without being able to list the contents. Every directory along a path needs the execute bit, which is why 755 rather than 644 is the directory default.
When is symbolic mode better than an octal value?
Octal sets all nine bits at once, which is what you want when you know the exact target state. Symbolic mode changes bits relative to what is already there: chmod u+x adds execute for the owner and leaves everything else alone, and chmod go-w strips write from group and others across a mixed tree without flattening the rest. The capital X form is especially useful, because chmod -R a+X adds execute only to directories and to files that already had it, so a recursive fix does not make every text file executable.
Why does chmod not fix a permission denied error caused by ownership?
The mode bits say what each of the three classes may do; ownership decides which class you fall into. If a file belongs to another user and you are neither its owner nor a member of its group, you are judged by the last digit, so loosening the owner bits changes nothing for you. The fix is chown or chgrp, or joining the owning group and starting a new login session. Note also that only the file owner and root may run chmod at all.
How do POSIX ACLs go beyond the three permission classes?
The classic bits describe exactly one owner and one group, so granting a single extra user write access has nowhere to live. POSIX ACLs, managed with getfacl and setfacl, add named user and group entries plus a mask that caps what those entries may actually receive. On a directory you can also set a default ACL that new children inherit. A file carrying an ACL shows a plus sign after the mode in ls -l, and the group bits shown there then represent the mask rather than the owning group.
Background & Theory
History
Reviewed for accuracy by Daniel Agrici, Founder & Lead Developer · Editorial policy
Related Calculators
🧮File Size Converter
Calculate file size converter with inputs, formulas, and instant results.
🧮Git Repository Size Calculator
Estimate repository size growth based on commit frequency, file sizes, and branching strategy.
🧮Data Compression Ratio Calculator
Calculate compression ratio and space savings from original and compressed file sizes.
🧮Bandwidth Time Transfer Calculator
Calculate bandwidth time transfer with inputs, formulas, and instant results.
🧮Download Time Calculator
Calculate download time with inputs, formulas, and instant results.
🧮Throughput Efficiency Calculator
Calculate throughput efficiency with inputs, formulas, and instant results.