In most cases (may vary depending on server configuration) for OctoberCMS all files should have 644 permissions and folders should have 755 permissions.
The next two commands need to be run one by one in the terminal, located at the root of the site (basically this is the public_html folder).
find ./ -type d -exec chmod 755 {} \;
find ./ -type f -exec chmod 644 {} \;
Also, in old versions of OctoberCMS (version 1.0.x, more about versions read here) in /config/cms.php
777 permissions were used by default (defaultMask option) for files and folders inside the storage directory. Therefore, it is better to check this first and then run commands to change permissions.