Directories, index files and permissions
Website location
/home/USER/domains/EXAMPLE.COM/public_html/Each domain has its own directory. When the account has multiple domains, use the full path through domains instead of relying on the home-directory public_html shortcut.
Index file
The web server looks for a file such as index.php or index.html. If a directory listing, default page or error appears, check the filename, location and application configuration.
Common permissions
| Object | Common value |
|---|---|
| Directories | 755 |
| Normal files | 644 |
| Sensitive configuration | Application-specific, often more restrictive |
These are guidelines. Never use 777 as a universal fix; it permits every process to write and can create a security problem.
File ownership
Correct numeric permissions do not help when files belong to another user. This can happen after copying as the wrong account or an administrator action. If files cannot be edited in DirectAdmin either, ask support to check ownership instead of using 777.
Files outside the public website
Do not store backups, database exports, private keys or password files in a publicly reachable directory. Keep them outside public_html or block access as documented by the application.