Chmod Calculator

Calculate Linux file permissions in octal or symbolic format.

Unix file permissions can be confusing with their octal notation and symbolic rwx flags. This free chmod calculator translates between numeric (e.g., 755) and symbolic (e.g., rwxr-xr-x) permission formats instantly. Build permissions visually with checkboxes or type an octal code to see the result. Everything runs locally in your browser for complete privacy.

Loading Chmod Calculator...
Your data stays in your browser
Was this tool useful?
Tutorial

How to use

1
1

Usage Step

Calculate Linux file permissions in octal or symbolic format.

Guide

Complete Guide to Unix File Permissions and chmod

What are Unix File Permissions?

Every file and directory on a Unix or Linux system has an associated set of permissions that control who can read, write, or execute it. Permissions are divided into three classes: owner (user), group, and others (world). Each class can independently have read (r), write (w), and execute (x) permissions. These nine permission bits, plus special bits like setuid, setgid, and sticky, form the complete permission model that protects files on Unix-like operating systems including Linux and macOS.

Understanding Octal Notation

Octal (base-8) notation represents each permission class as a single digit from 0 to 7. Read equals 4, write equals 2, and execute equals 1. Add the values for each class to get the digit: rwx = 4+2+1 = 7, r-x = 4+0+1 = 5, r-- = 4+0+0 = 4. The classic 755 means the owner can read, write, and execute, while group and others can only read and execute. This compact notation is used with the chmod command on the command line.

Symbolic vs Numeric chmod

The chmod command supports both symbolic and numeric modes. Symbolic mode uses letters (u, g, o, a) with operators (+, -, =) and permission letters (r, w, x). For example, chmod u+x file adds execute permission for the owner. Numeric mode sets all permissions at once: chmod 644 file gives rw-r--r--. Symbolic mode is better for incremental changes; numeric mode is clearer when setting all permissions from scratch.

Best Practices for File Permissions

Follow the principle of least privilege: grant only the permissions needed. Use 644 for regular files (owner reads and writes, everyone else reads), 755 for directories and scripts (owner has full access, others can read and enter), and 600 for sensitive files like SSH keys or configuration files with passwords. Avoid 777 (full access for everyone) in production as it creates serious security vulnerabilities. Always test permission changes in a staging environment first.

Examples

Worked Examples

Example: Setting Web Server File Permissions

Given: an HTML file that the web server (running as www-data in the group) must be able to read, but only the owner should modify.

1

Step 1: Owner needs read + write = 4+2 = 6.

2

Step 2: Group needs read = 4.

3

Step 3: Others need read = 4.

Result: chmod 644 index.html (rw-r--r--)

Example: Making a Script Executable

Given: a deploy.sh script that the owner should run, group members can read, and others have no access.

1

Step 1: Owner needs read + write + execute = 4+2+1 = 7.

2

Step 2: Group needs read + execute = 4+1 = 5.

3

Step 3: Others get no permissions = 0.

Result: chmod 750 deploy.sh (rwxr-x---)

Use Cases

Use cases

Web Server Configuration

Configure correct permissions for web server files: 644 for static HTML, CSS, and JavaScript files so the server process can read them, while only the owner can modify them. Use 755 for directories so the server can list their contents. Incorrect permissions are one of the most common causes of 403 Forbidden errors.

SSH Key Security

SSH requires strict permissions on key files: 600 for private keys (only the owner reads and writes) and 644 for public keys. If permissions are too open, SSH refuses to use the key with a warning. Use this tool to verify and calculate the exact permissions required for secure SSH authentication.

Deployment Scripts

Build and deployment scripts need execute permission for the owner (or group). A typical permission of 750 lets the owner run the script, group members can read it for auditing, and others have no access. This prevents accidental execution by unauthorized users while keeping the deployment workflow smooth.

Shared Directory Access

Team shared directories often use 2775 (setgid + rwxrwxr-x) so that new files created inside inherit the group ownership. This ensures all team members can read and write files regardless of who created them. The setgid bit is crucial for collaborative workflows on Linux servers.

Frequently Asked Questions

?What does chmod 755 mean?

chmod 755 sets permissions to rwxr-xr-x: the owner can read, write, and execute; group members and others can read and execute but not modify. It is the standard permission for directories and executable scripts.

?What is the difference between chmod 644 and chmod 755?

644 (rw-r--r--) allows the owner to read and write while others can only read. 755 (rwxr-xr-x) additionally grants execute permission to everyone. Use 644 for regular files and 755 for directories and scripts.

?How do I convert octal permissions to symbolic?

Enter the octal number (e.g., 755) into the calculator and the symbolic representation (rwxr-xr-x) appears instantly. Each octal digit maps to a combination of r (4), w (2), and x (1) for owner, group, and others.

?Why should I avoid chmod 777?

chmod 777 gives full read, write, and execute access to everyone on the system, creating a major security risk. Any user or process can modify or delete the file. Use the least privilege needed instead.

?What are setuid, setgid, and sticky bit?

Setuid (4) runs a file as its owner, setgid (2) runs it as its group or makes new files in a directory inherit the group, and sticky bit (1) prevents users from deleting files they do not own in a shared directory.

?Is this chmod calculator free to use?

Yes, completely free with no registration, no usage limits, and no ads. Calculate permissions as often as you need.

?Does this tool send my data to a server?

No. Everything runs locally in your browser. No data is transmitted anywhere. Your permission calculations remain private.

?Can I use this for macOS file permissions?

Yes. macOS uses Unix-style permissions identical to Linux. The octal and symbolic notations work the same way on both systems.

Help us improve

How do you like this tool?

Every tool on Kitmul is built from real user requests. Your rating and suggestions help us fix bugs, add missing features and build the tools you actually need.

Rate this tool

Tap a star to tell us how useful this tool was for you.

Suggest an improvement or report a bug

Missing a feature? Found a bug? Have an idea? Tell us and we'll look into it.

Related Tools

Recommended Reading

Recommended Books on Linux & Unix System Administration

As an Amazon Associate we earn from qualifying purchases.

Boost Your Capabilities

Professional Products to Boost Your Development Setup

As an Amazon Associate we earn from qualifying purchases.

Newsletter

Get Free Productivity Tips & New Tools First

Join makers and developers who care about privacy. Every issue: new tool drops, productivity hacks, and insider updates — no spam, ever.

Priority access to new tools
Unsubscribe anytime, no questions asked