October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsClean PCRecommendedOne scan can reveal what keeps slowing WindowsLook for cleanup and repair opportunities.Run ScanOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk4 min

How to Read chmod 644, 755, and Four-Digit Modes

Decode chmod numeric modes: understand the 4-2-1 permission values, read 644 and 755, and learn what a fourth digit and directory execute permission mean.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

In chmod 755, the three digits describe permissions for the file’s owner, its group, and everyone else—in that order. Each digit adds values for read (4), write (2), and execute or directory search (1). So 755 gives the owner all three permissions and gives group members and others read and execute/search access.

How to read a three-digit chmod mode

Numeric modes are octal, or base 8. GNU Coreutils 9.11 explains that they are interpreted as octal without needing a leading zero. The three ordinary digits map to these user classes:

As an Amazon Associate I earn from qualifying purchases.

  1. First digit: the file’s owner.
  2. Second digit: users in the file’s group.
  3. Third digit: everyone else.

Each digit is the sum of the permission values it includes:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Value Permission Meaning
4 Read Read a file’s contents; on a directory, list its entries.
2 Write Modify a file; on a directory, create or remove entries, subject to other rules.
1 Execute/search Run an executable file; on a directory, search or access entries when the user knows their names.

Add the values to form each digit: 7 is 4+2+1 (read, write, execute/search); 6 is 4+2 (read and write); 5 is 4+1 (read and execute/search); and 4 is read only. For the full definitions, see the GNU Coreutils 9.11 manual’s mode-bit structure and its numeric modes section.

What chmod 644 and chmod 755 allow

The number only makes sense when you know which object it applies to. On a regular file, execute means permission to run it; on a directory, the same bit means search or access. These examples describe the resulting permissions, assuming the command succeeds:

Command Owner Group Others Typical effect on a regular file
chmod 644 file Read, write Read Read The owner can edit; group members and others can read, but none can execute it.
chmod 755 script Read, write, execute Read, execute Read, execute The owner can edit and run; group members and others can read and run.

GNU’s chmod invocation documentation uses chmod 644 foo as an example of making a file readable by everyone while retaining write access for its owner. Neither mode is universally best: choose according to who needs access and whether the target is a file or directory.

Why directory permissions behave differently

For a directory, read allows listing its contents, write allows creating or removing entries, and execute allows searching the directory to access entries. For example, a user needs search permission on a directory to access a known file inside it. Directory write access is not the same as permission to edit every file in that directory; each file’s own permissions and other system rules still matter. GNU Coreutils describes these distinctions in its mode-bit structure documentation.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

What a fourth digit means

A fourth digit at the front represents special mode bits; it is not a fourth user category. Its values are:

Leading value Special bit General effect
4 Set-user-ID On applicable executable files, affects the effective user ID when run; behavior depends on file type and system.
2 Set-group-ID On applicable executable files, affects the effective group ID; on most systems, on a directory it makes new entries inherit the directory’s group, and new subdirectories inherit setgid.
1 Sticky or restricted-deletion bit On a directory, restricts who may remove or rename entries: users generally must own the entry or the directory, or have appropriate privilege.

For example, 4751 combines set-user-ID (4) with owner read, write, and execute (7), group read and execute (5), and other execute (1). Special-bit effects vary by file type and system; consult the GNU Coreutils directory setuid and setgid documentation for GNU’s details.

Does chmod replace permissions or add to them?

A plain numeric mode such as chmod 644 file sets the specified permission bits as a mode; it does not mean “add these permissions to whatever is there now.” The result may also be affected by system rules such as a process umask when permissions are initially created, but a plain numeric chmod is not an incremental addition.

GNU also supports operator numeric modes such as +440, -1, and =600. These use operators to add, remove, or set bits rather than simply applying the ordinary three-digit mode. The GNU manual explicitly notes, “Operator numeric modes are a GNU extension.” Do not assume they are portable to every system. GNU also documents that chmod =755 dir and chmod 755 dir differ in their treatment of setuid/setgid bits on directories. See the operator numeric modes section for those GNU-specific semantics.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

How to apply a mode without changing the wrong files

  1. Identify the target. Confirm the exact file or directory. Check ownership and current permissions with a listing such as ls -l path; a leading d in the mode display identifies a directory.
  2. Choose the intended access. Decide separately what the owner, group, and other users should be able to do, then add 4, 2, and 1 for each class. Remember that directory execute means search, not running the directory.
  3. Run chmod on the exact path. For example, chmod 644 report.txt gives the owner read/write and group and others read access. The command generally requires ownership of the file or appropriate privileges.
  4. Check the result. Run ls -l path again and verify the permission string matches the intended mode. If it does not, check whether you have sufficient privileges and whether the path names a symbolic link or directory.

For a command-line symbolic-link argument, GNU chmod normally changes the target’s permissions, not the link’s. Links encountered during recursive traversal are handled differently. Recursive changes can affect many files, so inspect the scope first—for example, run find project -maxdepth 2 -print before using a recursive command. Only if that list is the exact scope intended should you consider chmod -R 755 project; that command applies broadly and can make files executable as well as directories searchable. GNU documents link handling and recursive behavior in its chmod invocation reference.

Further reading

For a broader introduction to using the command line, William Shotts’s The Linux Command Line is a beginner-oriented guide; its author’s page offers a free digital edition. Edition and print availability can change, so check the current listing on that page.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
PC Slower Than It Used to Be?Free scan - under a minute
Crashes, No Sound, or Screen Glitches?Free driver scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.