How to change file permissions in WordPress

To protect your website from malicious activity, we recommend that you secure your WordPress files and folders by changing their file permissions. File permissions determine who can read, write, modify, and delete files or folders on your HostPapa server.

In this article, we’ll show you how to change file permissions in WordPress using an FTP client or the cPanel File Manager.

Changing file permissions using an FTP client

Many FTP client applications are available for Windows PCs, Macs, and Linux computers, and some are even free to download. Two popular options are FileZilla and CoreFTP. Open your FTP application and enter your HostPapa FTP server details. To retrieve these credentials, follow these instructions:

  1. Log in to your HostPapa Dashboard
  2. Go to My cPanel or My WordPress.

    How to change file permissions in WordPress

  3. Clic FTP Accounts.

    How to change file permissions in WordPress 1

  4. Locate your FTP Account and click Configure FTP Client.

    How to change file permissions in WordPress 2

  5. If you are using FileZilla, CoreFTP or Cyberduck FTP, you can download and import your FTP configuration details from the cPanel dashboard.

    How to change file permissions in WordPress 3

  6. Once logged in, navigate to your WordPress folder. 
  7. Right-click the folder and select File permissions

    How to change file permissions in WordPress

  8. HostPapa recommends that WordPress folder permissions be set to 755 and that files be set to 644.
  9. Enter 755 in the Numeric Value field and ensure the box next to Recurse into subdirectories is checked.
  10. Below, click the radio button next to Apply to directories only.

    How to change file permissions in WordPress 5

  11. Click OK to continue.
  12. Enter the WordPress folder and look for your index.php file. 
  13. Right-click the file and, once again, select File permissions

    How to change file permissions in WordPress 6

  14. This time, set the Numeric Value to 644 and click OK.

    How to change file permissions in WordPress 8

You can find out more about working with FTP in our Knowledge Base.

Changing file permissions using cPanel File Manager

Alternatively, you can use cPanel File Manager to change the file and folder permissions in your WordPress installation.

  1. Log in to your HostPapa Dashboard
  2. Go to My cPanel or My WordPress.

    How to change file permissions in WordPress

  3. Select File Manager.

    How to change file permissions in WordPress 9

  4. Right-click on your WordPress folder and select Change Permissions.

    How to change file permissions in WordPress 11

  5. Enter 755 in the Permission fields.
  6. Click Change Permissions to continue.
  7. Double-click your WordPress folder and find the index.php file. 
  8. Right-click the file and, once again, select Change Permissions.
  9. Set the Permission value to 644 and click OK.

    How to change file permissions in WordPress 11

If you need help with your HostPapa account, please open a support ticket from your dashboard.

Related Articles

Get online with our affordable web hosting

Get online with our affordable web hosting

Learn more now
HostPapa Mustache