Reset Permissions to WordPress Site for Files and Directories

If your permissions are incorrect for files and folders in a webroot domain of a WordPress site more than likely you’ll get a server 500 error. Here is how to fix them by resetting the permissions via the command line, especially using the correct defaults for a cPanel domain or other web server for files and directories.

You can bulk fix these permissions on the command line, with these commands:

cd /home/yourdomain/public_html/

Go to your webroot directory

find . -type d -exec chmod 755 {} \;

Fix and rest the permissions on directories

find . -type f -exec chmod 644 {} \;

Fix and reset the permissions on files.

That’s it all permissions are now correct.

1 comment

  • Ayo criag

    you are wonderful for this post …i mistakenly chmod the wp-content and everything went wrong,i googled for solutions and found your website …thank you for support my site is working properly now …great work

Leave your comment