Whether you are a website owner or a visitor, you may be greeted with a message informing you that something is “Forbidden”, i.e., that you don’t have permission to view something on your site. If that’s the case, the odds are good you’ve encountered the 403 Forbidden error. This one that occurs in the browser can annoying and problematic. Hence, you need to check out our 403 Forbidden error guide and get acquainted with ways to fix it. But first, let’s learn more about this error and why it creeps up in your browser.
What is the 403 Forbidden Error?
Did you try to visit a website or another resource in your web browser and got the 403 Forbidden error? That’s because the webpage (or another resource) you’re attempting to open is not allowing you to access the information or resources. Because of this error code, it’s called a “403” error.
It is most often caused by one or two things. The first is that the server’s owners have correctly assigned access permissions, but you are not permitted to open the resource. Secondly, server owners may have improperly set up permissions, and you are denied entry.
Website designers can modify the appearance of a 403 error like they could with other types of errors (404 and 502, for instance). Therefore, websites occasionally use alternative names for this error, and, for example, you may find messages such as:
- 403 Forbidden
- HTTP 403
- Forbidden
- HTTP Error 403 – Forbidden
- HTTP Error 403.14 – Forbidden
- Error 403
- Forbidden: You don’t have permission to access [directory] on this server
- Error 403 – Forbidden
How to Fix the 403 Forbidden Error on the Client Side
Most of the time, you can’t do much yourself unless you are the admin of the site. You’re either not allowed to access the resource, or there’s an error on the server-side. It might be a momentary blip or something more serious.
Whatever it is, there are nonetheless certain things you can try to do to fix the 403 Forbidden error:
1. Refresh the Web Page
It’s always worth a shot to refresh the page. The 403 error is frequently fleeting, and a quick reload can solve the problem. Most browsers have the option to refresh in the form of Ctrl + R on Windows or Cmd + R on Mac or by pressing F5.
2. Check the Web Page URL
When you see a 403 Forbidden error, inspect the URL you’re attempting to use. Often, the problem is just a matter of spelling or typing something incorrectly.
For example, if you were trying to view www.example.com/tester and instead typed in www.example.com/teste (notice that there’s no “r” at the end), you would receive a 403 Forbidden error for that specific page only. In this case, the server may still be accessible but is not showing you the proper content because of a typo or misconfiguration.
3. Clear Your Browser Cache
If the issue persists, try clearing your browser’s cache. This is different from refreshing because it clears out all information that your browser has stored about the website in question. The process for doing this varies depending on which browser you’re using. To help you, we wrote guides on clearing Chrome cache on Windows and ways to clear Firefox cache on Windows.
4. Try a Different Browser
Before opting for the manual handy stuff, like restarting the PC or router, check for the same using a different browser. Your old browser may be configured to prevent you from accessing the website. To test this, try accessing the website using a different browser. If the problem persists, your computer may have an issue. In this case, you should try restarting your computer and trying again.
5. Restart Your Router
If you’re still seeing a 403 Forbidden error, there may be something wrong with your network connection. To test this, try restarting your router or modem. Once they’ve been turned off for a few minutes, turn them back on and try accessing the website again.
If the difficulty persists, then there may be an issue with your Internet Service Provider (ISP). In this case, you should contact them and let them know about the 403 error.
6. Disable Your VPN
If you’re using a VPN, try disabling it and accessing the website again. However, if the concern remains, your VPN may have an issue. In this case, you should contact your VPN provider and let them know about the 403 error.
If your preferred website is inaccessible, you can still use VPNs to unblock it. However, because individual websites block some VPN servers, you could want to consider changing the server or switching to another service entirely.
7. Contact the Website Owner
If you’ve gone through all the above troubleshooting steps and still see a 403 Forbidden error, the website itself may be causing the problem. In this case, you should contact the website owner and inform them about the 403 error. They may be unaware and could help you solve the problem.
2. Website Owner Guide to Fix the 403 Forbidden Error
There are many ways to build a website, but WordPress is undoubtedly among the most popular. Therefore, WordPress website owners can do this to fix the 403 Forbidden error:
1. Disable Your WordPress Plugins
If your WordPress site uses plugins, try temporarily disabling them one by one and accessing your website after each deactivation to see if the difficulty is solved. Often, a 403 Forbidden error caused by a plugin will be accompanied by an error message telling you which one is the culprit.
2. Check for Errors in the .htaccess File
The .htaccess file is a configuration file used by Apache-based web servers to alter their server’s behavior. If there’s an error in the file, it can cause a 403 Forbidden error. To check for this, look for a line that starts with “AllowOverride” in your site’s httpd.conf file.
- If AllowOverride is set to None, then .htaccess files are not being read by the server.
- If AllowOverride is set to something else (e.g., AllowOverride All), then check your .htaccess file for errors.
3. Set File and Folder Permissions
The most common reason for a 403 Forbidden error involves file permissions. WordPress has them aplenty, but they shouldn’t cause any problems for the site administrator. However, these configurations can inadvertently be altered from time to time.
Fortunately, this is easy to solve. First, locate the root directory of your WordPress site using your FTP client and look for wp-admin, wp-content, and wp-includes folders. Next:
- File Attributes should be selected on the parent folder’s “File Attributes” tab.
- Fill in the value of 755 and then click on the OK button.
- Check the box labeled Recurse into subdirectories, and select Apply to directories only.
- Click the OK button to complete this process. This will automatically grant all required permissions.
- You’ll need to repeat the process for files inside. However, this time, you’ll enter 644 in the number field and pick Apply to files only, then OK when you’re ready.
- Return to your site’s root folder and look for your wp-config.php file. Next, select File Attributes from the menu that appears when you right-click on it.
- After entering the number 644, click on the OK button. If WordPress file permissions caused the error, changing permissions for files and folders should fix it.
Common causes of a 403 Forbidden error and their potential fixes
The following table explores the various causes of a 403 forbidden error and the potential solutions to them:
Cause | Description | Potential Solution |
---|---|---|
Insufficient Permission | When the user doesn’t have all the necessary permissions for access | Review and update user roles and permissions |
Incorrect configuration | Server settings misconfigured, such as incorrect paths or access rules applied | Double-check access control lists (ACLs) and use Apache or Nginx to verify server settings |
IP blocked | The IP address of the user has been blocked by either the website or the ISP | Use a VPN or other obfuscation solutions |
Authentication issues | When the user uses incorrect credentials or the session expires | Make sure to use the correct ID and Password |
Firewall restrictions | A firewall preventing access to the source | Whitelist website |
Server Overload | Due to heavy traffic, the server is unable to handle the request | Wait for a while before trying again |
Directory Listings | No index file was found, so access was revoked. | Add an index file to the directory and adjust the settings accordingly |
Ownership | Incorrect ownership can result in the revocation of access | Ensure proper ownership |