Current Permission
{{ fullNumeric }}
{{ fullSymbolic }} Special {{ specialOctal }} Directory File
Presets
Permissions

{{ label }}

Special Bits
Direct Editing
Options
Target
Umask Explorer
umask
File base
Dir base
File →
Symbolic
Dir →
Symbolic
Field Value Copy
Numeric {{ fullNumeric }}
Symbolic {{ fullSymbolic }}
chmod command {{ command }}
ls -l preview {{ lsOutput }}
User / Group / Others {{ uTriplet }} · {{ gTriplet }} · {{ oTriplet }}

            

Common ops:

  • a+rwX add read/write to all; add execute only for directories or if any exec already set
  • u=rwx,go=rx owners full; group/others read/execute
  • g=u copy user bits to group
  • u-s,g-s,o-t clear setuid, setgid, sticky

These apply relative to the current matrix via Apply op.

Introduction:

Unix-like systems express access control with file mode bits, often called permissions or a permissions matrix. The chmod command—short for “change mode”—adjusts bits for the owner, group, and others, plus optional special flags controlling execution or deletion behavior. This explanation maps human-readable forms to octal digits so you can reason clearly about outcomes with minimal trial and error. If you are looking for a chmod calculator online, this page provides a concise, practical overview. [oai_citation:0‡metadata.json](file-service://file-2XzGuyxUz5EU4JkxaWJQFa)

You supply either numbers in octal form or symbolic tokens that describe read, write, and execute capabilities for user, group, and others, with optional special flags. The utility converts between representations, previews an ls -l-style permission string, and composes a command reflecting your selections. These results help you audit repository defaults, prepare deployment scripts, and understand how a process umask affects new files or directories across typical Unix and POSIX environments. [oai_citation:1‡app.html](file-service://file-8CpCzhz6iWn7SA26EYKqzb)

Example: a private log might grant the owner read and write access, grant the group read access, and deny access to others—symbolically rw-r----- and numerically 640. Reading the output shows exactly which bits change and how the corresponding command would look before you run it. Use least‑privilege settings on multi‑user systems, because permissive bits can expose data or enable execution where none was intended.

Technical Details:

Concept Overview

Each permission digit encodes read, write, and execute using weights 4, 2, and 1 for the user, group, and others triplets. A leading “special” digit optionally sets setuid, setgid, and the sticky bit. Symbolic forms (u, g, o with r, w, x) map directly to those weights. A process umask clears bits when new paths are created: the effective mode equals a base permission bitwise‑AND the complement of the mask, typically using separate bases for files and directories. [oai_citation:2‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S) [oai_citation:3‡app.html](file-service://file-8CpCzhz6iWn7SA26EYKqzb)

Core Equation or Process

  1. Compute each entity digit:
    du=4·ru+2·wu+1·xu
    dg=4·rg+2·wg+1·xg
    do=4·ro+2·wo+1·xo
  2. Concatenate digits to form the octal mode; optionally prefix a special digit where setuid (4), setgid (2), or sticky (1) apply.
  3. For umask simulation, apply per‑digit bitwise logic:
    p=b¬m
    where p is the effective permission, b is the base (files or directories), and m is the mask. [oai_citation:4‡app.html](file-service://file-8CpCzhz6iWn7SA26EYKqzb) [oai_citation:5‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)

Interpretation & Thresholds

Octal Digit Triplet Meaning
0---No permissions
1--xExecute only
2-w-Write only
3-wxWrite and execute
4r--Read only
5r-xRead and execute
6rw-Read and write
7rwxRead, write, and execute
Special Flag Octal Addend Effect Long Listing
setuid (u+s)4Run as file owners if user execute set, otherwise S
setgid (g+s)2Run as group; inherit group on dirss if group execute set, otherwise S
sticky (o+t)1Restrict deletes in world‑writable dirst if others execute set, otherwise T

The long‑listing preview shows these letters in the execute position of each triplet; uppercase appears when the corresponding execute bit is not set. [oai_citation:6‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)

Variables & Parameters

Parameter Meaning Unit/Datatype Typical Range Notes
Numeric mode Direct octal entry with optional special digit String of octal digits 3–4 digits Validated; only 0–7; width sanitized and padded or trimmed. [oai_citation:7‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
Symbolic (direct) Canonical u=…, g=…, o=… triplets Comma‑separated tokens Letters r, w, x Also accepts u+s, g+s, o+t; capital X is not applied in this field. [oai_citation:8‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
Apply op chmod‑style relative operations Pattern [ugoa][+-=][rwxXst] or copy [ugoa]=[ugo] One or more comma‑separated ops X adds execute only for directories or when any execute is already set; copy ops like g=u are supported. [oai_citation:9‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
Options Command switches and target Booleans and path string Recursive, verbose, directory flag Used to compose the command; nothing is executed in the browser. [oai_citation:10‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
Umask fields Simulate creation defaults 3‑digit octal masks and bases Files base 666; dirs base 777 Effective = base & ~mask; outputs both octal and symbolic. [oai_citation:11‡app.html](file-service://file-8CpCzhz6iWn7SA26EYKqzb) [oai_citation:12‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)

Worked example: Owner needs read and write; group needs read; others need none. The digits are:

du=4·1+2·1+1·0=6 dg=4·1+2·0+1·0=4 do=0

So the mode is 640 (rw-r-----). If the process umask is 027 and a file base is 666, the creation result is:

p=666¬027=640

Assumptions & Limitations

  • Octal inputs accept only digits 0–7; invalid or empty values are ignored after sanitation. Heads‑up [oai_citation:13‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  • Capital X applies only in the relative Apply op field, not in direct triplet editing. Heads‑up [oai_citation:14‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  • The composed command string is for copying; nothing is executed by the page. [oai_citation:15‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  • The long‑listing preview uses fixed owner/group, size, and timestamp placeholders for demonstration. [oai_citation:16‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  • “Target is a directory” affects the listing prefix and whether X is eligible to add execute. [oai_citation:17‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)

Edge Cases & Error Sources

  • Leading zeros in octal are stripped during sanitation; width is padded or trimmed to 3–4 digits internally. [oai_citation:18‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  • Unrecognized symbolic tokens in Apply op are skipped silently; valid ones still apply in sequence. [oai_citation:19‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  • Copy operations use a single source entity (for example, g=u); multiple source letters are not supported in one copy. [oai_citation:20‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  • Special bits toggle with +s/-s and +t/-t but display as uppercase when execute is absent. [oai_citation:21‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  • Direct symbolic editing recognizes only u=, g=, o= plus u+s, g+s, o+t; other directives are ignored there. [oai_citation:22‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)

Scientific/Standards Backing

Behavior follows the POSIX definition of file mode bits and the chmod and umask utilities, GNU Coreutils chmod documentation, and traditional BSD man pages for chmod and umask.

Privacy & Compliance

Processing occurs entirely in your browser; no data is transmitted or stored server‑side. Clipboard copying and CSV/JSON exports use local browser APIs. The page composes command strings but does not modify your filesystem. For personal data, comply with internal policies and GDPR principles. [oai_citation:23‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S) [oai_citation:24‡style.css](file-service://file-UMk1UtutyJucWZa1ZkFEkM)

Step‑by‑Step Guide:

Use this sequence to translate, tweak, and copy permissions with confidence.

  1. Select a starting point using presets or by checking read, write, and execute for user, group, and others.
  2. Toggle Special bits when setuid, setgid, or sticky behavior is required.
  3. Edit Numeric mode directly if you know the octal; include a leading digit for special bits when needed. [oai_citation:25‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  4. Or edit Symbolic triplets with u=, g=, o=; you may add u+s, g+s, o+t here. [oai_citation:26‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  5. Use Apply op for relative changes like a+rwX or g=u. X obeys directory/execute rules. [oai_citation:27‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  6. Set options for recursion and verbosity, mark whether the target is a directory, and enter a path to compose the command. [oai_citation:28‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)
  7. Explore Umask by entering a mask and bases; review the resulting octal and symbolic for files and directories. [oai_citation:29‡app.html](file-service://file-8CpCzhz6iWn7SA26EYKqzb)

Example: apply g=u,o-rwx to mirror owner permissions to group and revoke all from others; verify the long‑listing preview and copy the composed command when satisfied. [oai_citation:30‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)

You now have a clear, auditable mapping from intent to octal, symbolic, and a ready‑to‑paste command.

FAQ:

What does chmod stand for?

chmod abbreviates “change mode,” the utility that sets file and directory permission bits on Unix‑like systems.

Is my data stored anywhere?

No. The page computes, previews, and exports entirely in your browser; clipboard and downloads use local APIs. No commands are executed or sent to servers. [oai_citation:31‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)

Which formats can I enter?

Enter 3–4 digit octal for numeric mode or symbolic triplets using u=, g=, o=. Relative ops like a+rwX and copies like g=u are supported in the Apply field. [oai_citation:32‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)

How accurate is the long listing?

The permission characters reflect your selections, including s/S and t/T rules. Owner, group, size, and time are placeholders for illustration only. [oai_citation:33‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)

Can I work offline?

Once loaded, the logic runs client‑side without additional network calls. Availability offline depends on how the host serves the page and your browser caching.

What about JSON and CSV?

You can copy or download a JSON payload and a compact CSV of computed values; the JSON panel uses local syntax highlighting in the UI layer. [oai_citation:34‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S) [oai_citation:35‡style.css](file-service://file-UMk1UtutyJucWZa1ZkFEkM)

Is there any license noted?

No explicit license text appears in the supplied package; consult the hosting site for licensing and reuse terms. [oai_citation:36‡metadata.json](file-service://file-2XzGuyxUz5EU4JkxaWJQFa)

Troubleshooting:

  • Numeric field does nothing: ensure only octal digits and a maximum of four characters are entered.
  • Capital X not applied: use the Apply field or mark the target as a directory.
  • Copy buttons fail: grant clipboard permission or try the context menu alternative.
  • Unexpected uppercase S/T: the corresponding execute bit is not set.
  • Umask outputs empty: provide valid three‑digit octal for both mask and bases. [oai_citation:37‡script.js](file-service://file-BF2hv2Gk4ssoTqrRH8zb8S)

Advanced Tips:

  • Tip Use presets as guardrails, then refine with a minimal set of relative ops like o-rwx.
  • Tip Mirror permissions quickly with g=u or o=g when teams clone owner access.
  • Tip Prefer a+rwX over a+rwx to avoid accidentally setting execute on regular files.
  • Tip Verify umask outcomes for CI artifacts to prevent world‑writable or world‑readable surprises.
  • Tip Treat setuid and setgid sparingly; audit ownership and verify binaries originate from trusted sources.

Glossary:

Permissions matrix
User, group, and others bits forming three octal digits.
Triplet
Three characters like rwx describing one entity’s access.
setuid (u+s)
Run executable with file owner’s user ID.
setgid (g+s)
Run with group ID; on directories, enforce group inheritance.
Sticky bit (o+t)
Only owner/root can delete within world‑writable directories.
Umask
Bitmask cleared from creation bases for files and directories.
Symbolic mode
Letters and operators expressing adds, removes, or copies.
Octal mode
Base‑8 digits encoding read, write, and execute weights.
Long listing
ls -l format previewing permission characters and type.
[oai_citation:38‡metadata.json](file-service://file-2XzGuyxUz5EU4JkxaWJQFa)