chmod 500 (r-x------) explained

The owner can read and execute; the group has no access; others have no access.

Octal
500
Symbolic
r-x------
ls -l shows
-r-x------

Who can do what

Class Read (4) Write (2) Execute (1) On a directory
Owner (u)YesNoYesList the files. Enter it and open files inside.
Group (g)NoNoNoNo access.
Others (o)NoNoNoNo access.

When to use chmod 500

Lets only the owner read and execute, with no write access for anyone.

Used for private scripts or directories that should not change by accident, readable and runnable only by their owner.

Commands

Set the mode with octal digits, or with the equivalent symbolic form:

chmod 500 path/to/file
chmod u=rx,g=,o= path/to/file

To apply it to every directory below a folder (and not to the files), combine it with find:

find path/to/folder -type d -exec chmod 500 {} +

chmod -R 500 changes files and directories alike, which is rarely what you want: directories usually need execute, regular files usually should not have it.

Work out any mode in the Chmod Calculator