Do you have a 403 Forbidden issue on your WordPress site? It is one of the most horrible mistakes that a WordPress newcomer may make. This tutorial will describe how to simply resolve the 403 prohibited issue in WordPress.
What is a 403 Forbidden - Access Denied WordPress Error?
Table of Contents
- 1 What is a 403 Forbidden - Access Denied WordPress Error?
- 2 What Causes a WordPress 403 Forbidden Error?
- 3 Resolving the 403 Forbidden Error in WordPress
When an issue occurs on your website, WordPress displays codes and notifications. Check out our list of the most frequent WordPress issues and how to resolve them.
On a WordPress site, a 403 Forbidden status code is shown.
When your server restrictions prevent access to a certain page, the 403 Forbidden error code is shown.
As a result, the mistake is frequently accompanied by the following text:
Forbidden – 403 On this server, you do not have permission to access ‘/’.
A 403 Forbidden error was also encountered while attempting to handle the request with an ErrorDocument.
This mistake can appear in a variety of settings. As an example:
- 403 Forbidden – Access to the wp-admin or WordPress login page has been denied.
- 404 Not Found – during WordPress installation.
- When browsing any page on your WordPress site, you will see a 403 Forbidden error.
- It is also conceivable that you will simply receive ‘Access Denied’ rather than the full 403 Forbidden status.
- Access to yourdomain.com may also be prohibited. You do not have permission to see this page.’
Now that you’ve learned about the many forms of 403 errors, let’s look at what produces them.
What Causes a WordPress 403 Forbidden Error?
Poorly setup security plugins are the most prevalent source of the 403 Forbidden error in WordPress. Many WordPress security plugins have the ability to ban an IP address (or a group of IP addresses) if they suspect them of being malicious.
This is why we utilize Sucuri to secure all of our WordPress sites.
A corrupt .htaccess file or improper file permissions on your server might also be the culprit.
Your WordPress hosting provider may occasionally make inadvertent modifications to their server settings. This might cause a 403 Forbidden error on your website.
After that, let’s look at how to fix a 403 prohibited error in WordPress.
Resolving the 403 Forbidden Error in WordPress
We recommend that you generate a complete WordPress backup of your website before proceeding. Here’s how to build a backup of WordPress manually.
If you were previously using an automated WordPress backup plugin, make sure you have access to the most recent backup before proceeding.
1. Troubleshooting a 403 Forbidden Error Caused by a WordPress Plugin
The first step is to temporarily disable all WordPress plugins. This includes any security plugins you’ve put on your site.
If this solves your problem, it suggests that one of your website’s plugins was creating the error.
You can determine which plugin was generating the issue by activating each one one at a time until you can duplicate the 403 prohibited error.
2. Resolve the 403 Forbidden Error Caused by a Corrupt .htaccess File
A corrupt .htaccess file on your WordPress site is frequently the source of the 403 error. This file can be easily repaired.
To begin, connect to your website through cPanel’s FTP client or file manager.
Then, in the root folder of your WordPress site, locate the .htaccess file. If you can’t find the .htaccess file in your WordPress folder, follow this procedure.
You must save the .htaccess file to your computer in order to keep a current backup. Following that, you must remove the file from your server.
Try visiting your website. If the 403 prohibited error is resolved, it suggests your .htaccess file was corrupt.
Log into your WordPress admin area and navigate to the Settings » Permalinks page to create a new .htaccess file.
Simply click the Save Changes button at the bottom of the page to have WordPress create a new .htaccess file.
3. Resolve the 403 Forbidden Error in WordPress Caused by File Permissions
File permissions are assigned to all files on your website. These file permissions govern who has access to your website’s files and directories.
The 403 prohibited error might be caused by incorrect file permissions. It causes your web server to believe you do not have authorization to view those files.
If the first two methods do not resolve the 403 prohibited issue on your site, the most likely cause is improper file permissions.
You can request that your WordPress hosting provider examine your website for proper file permissions. Some hosts are quite helpful; they won’t mind and will most likely fix it for you.
Making changes to file permissions on your own might have catastrophic implications. If you are unsure about doing it yourself, contact a friend for assistance or hire an expert.
If you want to do it yourself, this is how you would verify your file permissions.
Simply use an FTP program to connect to your WordPress site. Go to the root folder, which contains all of your WordPress files.
Right-click to choose a folder, then choose File Permissions from the menu.
Your FTP client will display a file permissions dialog box similar to this:
The file permissions on all folders on your WordPress site should be 744 or 755.
The file permissions for all files on your WordPress site should be 644 or 640.
You can adjust the root folder’s file permissions to 744 or 755. Check the box next to ‘Recurse into subdirectories,’ then check the ‘apply to directories only’ option.
Select the OK button. Your FTP client will now begin changing the permissions of all subdirectories in that folder.
After that, you must repeat the process for all of the files. This time, use file permissions of 644 or 640, and don’t forget to check the boxes for’recurse into subdirectories’ and ‘apply to files only.’ options.
When you click the OK button, your FTP client will begin adjusting file permissions for all of the specified files.
If you try to visit your website now, the 403 prohibited error should be gone.
We hope this information was useful in resolving the 403 prohibited error in WordPress. You may also be interested in our professional tips and tricks for securing your WordPress admin area.
If you like this post, please subscribe to our WordPress video tutorials on YouTube. We may also be found on Twitter and Facebook.