Skip to content

Chmod Calculator (Linux Permissions)

Convert Linux file permissions between checkboxes, octal and symbolic notation. For example, 755 is rwxr-xr-x and 644 is rw-r--r--.

Runs in your browser Free, no sign-up
Loading tool workspace...

What is Linux Chmod Permissions Calculator?

This chmod calculator converts Linux and Unix file permissions between checkboxes, octal codes and symbolic notation. Every file has three sets of permissions (owner, group and others), and each set can allow read (r), write (w) and execute (x). chmod expresses them as a three-digit octal number such as 755 or as a string such as rwxr-xr-x.

Tick the permissions you want, or start from a preset such as 755, 644, 700, 600 or 777, and the calculator shows the octal code, the symbolic notation and a ready-to-run chmod command, so you never have to work out the arithmetic by hand.

How to use Linux Chmod Permissions Calculator

  1. Choose a preset (755, 644, 700, 600 or
  2. or start from scratch.
  3. Tick Read, Write and Execute for the owner, the group and others.
  4. Read the octal code (for example
  5. and the symbolic notation (rwxr-xr-x).
  6. Copy the chmod command and run it in your terminal, replacing the file name.

Key features

  • Read, write and execute checkboxes for owner, group and others
  • Presets for 755, 644, 700, 600 and 777
  • Octal permission code that updates instantly
  • Symbolic notation such as rwxr-xr-x
  • Ready-to-copy chmod command

Common use cases

  • Setting permissions for web server files (644) and directories (755)
  • Making a shell script executable
  • Locking down private keys and credential files with 600
  • Fixing Permission denied errors on deployments
  • Learning how Unix permission bits work

Technical details & standards

Each permission has a value: read = 4, write = 2 and execute = 1. Adding the values of the ticked permissions gives one octal digit per set, written in the order owner, group, others. 7 (4 + 2 + 1) is rwx, 6 (4 + 2) is rw-, 5 (4 + 1) is r-x and 4 is r--.

So 755 is rwxr-xr-x: the owner can read, write and execute; group and others can read and execute. 644 is rw-r--r--: the owner can read and write, everyone else can only read. On directories, execute means permission to enter the directory and access the files inside it, which is why directories normally use 755 rather than 644.

Set Linux file permissions from the command line

Once the calculator gives you a mode, apply it with chmod. These commands cover the everyday cases on Linux and macOS.

Shell

chmod 644 index.html            # rw-r--r--
chmod 755 deploy.sh             # rwxr-xr-x
chmod u+x,go-w deploy.sh        # symbolic: add owner execute, remove group/other write

# Directories 755 and files 644 for a whole site
find site -type d -exec chmod 755 {} +
find site -type f -exec chmod 644 {} +

# Show the current numeric mode
stat -c "%a %n" deploy.sh       # Linux (GNU)
stat -f "%Lp %N" deploy.sh      # macOS and BSD

Python

import os, stat

os.chmod("deploy.sh", 0o755)                          # octal literal
oct(stat.S_IMODE(os.stat("deploy.sh").st_mode))       # '0o755'

Write the mode as 0o755 in Python. A plain 755 is a decimal number and sets very different permissions.

Common chmod values

The permission codes you will meet most often, with what each digit allows. Read the octal code left to right as owner, group, others; each digit adds read (4), write (2) and execute (1). On a directory, execute means permission to enter it.

OctalSymbolicWho can do whatTypical use
777rwxrwxrwxEveryone: read, write, executeAvoid: any user on the system can change or replace the file
775rwxrwxr-xOwner: read, write, execute; group: read, write, execute; others: read, executeShared directories that a team group writes to
770rwxrwx---Owner: read, write, execute; group: read, write, execute; others: noneDirectories only the owner and group may use
755rwxr-xr-xOwner: read, write, execute; group and others: read, executeDirectories, shell scripts and executables (the usual default)
750rwxr-x---Owner: read, write, execute; group: read, execute; others: noneDirectories and programs hidden from other users
700rwx------Owner: read, write, execute; group and others: nonePrivate directories such as ~/.ssh, and private scripts
666rw-rw-rw-Everyone: read, writeRarely right: a file anyone can modify
664rw-rw-r--Owner: read, write; group: read, write; others: readFiles a team group edits together
644rw-r--r--Owner: read, write; group and others: readRegular files such as HTML, CSS and config files
640rw-r-----Owner: read, write; group: read; others: noneConfig files a service's group needs to read
600rw-------Owner: read, write; group and others: noneSSH private keys, .env files and other credentials
444r--r--r--Everyone: readFiles nobody should modify
400r--------Owner: read; group and others: noneRead-only secrets, such as an AWS .pem key file

Frequently asked questions

What does chmod 755 mean?

755 is rwxr-xr-x: the owner can read, write and execute (7), while the group and everyone else can read and execute but not modify (5). It is the standard permission for directories, scripts and executables.

What does chmod 644 mean?

644 is rw-r--r--: the owner can read and write (6) and everyone else can only read (4). It is the usual permission for regular files such as HTML, CSS and configuration files on a web server.

Is chmod 777 safe?

Rarely. 777 lets every user on the system read, modify and execute the file, so any compromised account or process can change it. Grant the minimum needed instead, such as 755 for directories and 644 for files, and fix ownership with chown when the wrong user owns the file.

What permissions should an SSH private key have?

600 (rw-------): only the owner can read and write it. SSH refuses to use a private key that other users can read, showing an UNPROTECTED PRIVATE KEY FILE warning.

What does chmod +x do?

It adds execute permission so the file can be run as a program, for example ./deploy.sh. With no u, g or o in front, it applies to the owner, group and others, minus any bits blocked by your umask; with the usual umask of 022, a 644 file becomes 755. Use chmod u+x to make a file executable for its owner only.

What does chmod 700 mean?

700 is rwx------: the owner can read, write and execute, and nobody else has any access. It is the right permission for private directories such as ~/.ssh and for scripts only you should run.

What is the difference between chmod 644 and 755?

644 (rw-r--r--) is for regular files. 755 adds execute permission, which scripts and directories need.

What's the difference between 644 and 700?

644 (rw-r--r--) lets the owner read and write and everyone else read, which suits files that other users or a web server must read. 700 (rwx------) gives the owner read, write and execute and shuts everyone else out, which suits private directories and personal scripts. Mixing them up causes errors: a web page set to 700 cannot be read by a server running as another user, and a directory set to 644 cannot be entered, even by its owner.

What do the numbers in chmod mean?

Read = 4, write = 2 and execute = 1. Add them for each of owner, group and others.

Is my data safe?

Processing happens locally in your browser. Tool input is not sent to CodeUnpack servers.

Does it work offline?

Once the page has loaded, this tool can process input without an internet connection.

More calculators tools

View all