chmod 440 (r--r-----)

chmod 440 gives the owner read permission, the group read, and everyone else none. Read-only for owner and group, e.g. /etc/sudoers.

440Octal
-r--r-----ls -l (file)
u=r,g=r,o=Symbolic chmod

Change bits in the chmod calculator →

Breakdown

ClassDigitSymbolicReadWriteExecute
Owner (u)4r--✔——
Group (g)4r--✔——
Others (o)0---———

owner 4 = 4 · group 4 = 4 · others 0 = 0

Commands

chmod 440 file.txt
chmod u=r,g=r,o= file.txt     # same thing, symbolic
chmod -R 440 folder/        # recursive (careful: applies to files and directories)
find folder -type f -exec chmod 440 {} +   # only files

Applied to a directory

Things to know

Related modes

Frequently asked questions

What does chmod 440 mean?
Owner: r--, group: r--, others: ---. In ls -l output a file with this mode shows -r--r-----.
How do I set 440 with umask?
New files start from 666 and directories from 777, minus the umask. For new directories, umask 337 yields 440. For new files, umask 226 yields 440.