chmod 664 (rw-rw-r--) explained

The owner can read and write; the group can read and write; others can read.

Octal
664
Symbolic
rw-rw-r--
ls -l shows
-rw-rw-r--

Who can do what

Class Read (4) Write (2) Execute (1) On a directory
Owner (u)YesYesNoList the file names, but not open them.
Group (g)YesYesNoList the file names, but not open them.
Others (o)YesNoNoList the file names, but not open them.

When to use chmod 664

Lets the owner and the group read and write, and everyone else read.

The usual mode for files in a shared group directory: teammates can edit, others can read. It is what new files get with a umask of 002.

Commands

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

chmod 664 path/to/file
chmod u=rw,g=rw,o=r 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 664 {} +

chmod -R 664 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