The Unix chmod command sets file permissions, but its octal numbers are easy to get wrong. This calculator lets you tick read, write and execute for owner, group and other, then shows the octal value, the symbolic notation (rwxr-xr-x) and a ready-to-run chmod command. It works both ways — apply a preset and watch the checkboxes update.
How it works
Each of the three scopes (owner, group, other) gets one octal digit, formed by adding the permission bits it has: read = 4, write = 2, execute = 1. So read+write is 6, read+execute is 5, and all three is 7. The three digits are concatenated in the order owner-group-other. Symbolic notation expresses the same bits as a 9-character string, with a letter (r, w, x) where the bit is set and a dash where it is not.
| Permission | Octal | Symbolic |
|---|---|---|
| read | 4 | r— |
| read + write | 6 | rw- |
| read + execute | 5 | r-x |
| read + write + execute | 7 | rwx |
Example
For owner = read+write+execute, group = read+execute, other = read+execute:
owner 4+2+1 = 7, group 4+1 = 5, other 4+1 = 5 → 755 →
rwxr-xr-x→chmod 755 filename
This is the usual permission for directories and executable scripts. Presets cover 644 for files, 755 for executables and directories, 600 for private files, and 777 for full access. Everything runs in your browser; nothing is uploaded.