What Is 403 Forbidden Error? How to Fix It? [Various Steps]

In a server whenever you are not able to access any files that means you are facing a common problem i.e. 403 Forbidden Error, In this article, you will know how to fix it?

Updated: 14 Apr, 23 by Antoniy Yushkevych 6 Min

List of content you will read in this article:

In this article, we will explain what a 403 forbidden error is, as well as we will let you know 3 methods to fix it. 

Running a website, whether it be a blog, an e-commerce store, an information landing site, or anything in between, is crucial to your online presence. Just like with anything else related to technology, hiccups can occur within your site, making its user experience less than seamless.

Error messages are commonly occurring nuisances for anyone who runs a site. While some of these messages are more prevalent than others and are easy to decipher, some are not. If you have recently stumbled into a message that reads "403 Forbidden – you don’t have permission to access / on this server" and aren't sure what to do, this article will provide you with a few ways to easily solve it.

The 403 Forbidden Error is an HTTP status code that pops up when you try to go to a site whose access has been forbidden. The code also comes in the form of the following statements:

  • Access Denied You don't have permission to access
  • Forbidden: You don't have permission to access [directory] on this server
  • 403 forbidden requests forbidden by administrative rules
  • HTTP Error 403 – Forbidden

It sometimes will also simply read 403 Forbidden. Whatever the phrase used, it can still be a frustrating experience to encounter it. The reason you see this code in the first place is your website's way of making sure you or anyone else who is trying to access the page knows they do not have permission to do so. It is often caused by incorrect folder or file permissions, or incorrect settings within the .htaccess file.

The easiest way to take care of the problem comes in the form of the following steps:

  • Reset or rename the .htaccess file.
  • Reset the folder permissions alongside the file.
  • Disable any WordPress plugins you may have running.

Let's move to understanding various methods.

1. Check the .htaccess file

If you're unfamiliar with this file because it is typically hidden in the directory of the project. This file is a server configuration file that works by changing the Apache Web Server settings that alter the configuration. If you are using cPanel, you can find it by accessing the cPanel through the File Manager. To do so, follow these steps:

  • Use the Control panel to find the File Manager.
  • Look for the .htaccess file in the public_html directory.
  • If you can't find them, go into settings and enable the "show hidden files" option.

After finding the file, you will need to:

  • Download the .htaccess file to your computer in order to create a backup.
  • Delete the file once the backup has been created.
  • Try to access the website again.

If you can access it, it usually means the .htcaccess file was corrupt. Generate a new one by going to Settings and then Permalinks. Lastly, click on save changes.

2. Reset File and Directory Permissions

Another fix for the 403 forbidden error message is that you have bad permissions for your folders or individual files. Typically, when files are created, they are done with certain default Linux permissions

This will control how you execute, write, and read the files when you use them. Using an FTP client will help you edit your folder permissions.

  • Access the site files using any FTP client.
  • Look in the root directory of the account.
  • Choose the main folder that houses all site files and right-click to access "file attributes".
  • Choose "Apply to directories only".
  • Enter permission number 755 in the field for numeric values.
  • Press O.

Once that is completed, follow these steps to finish:

  • Go back to the main folder that houses all site files and right-clicks to access "File attributes".
  • Choose "Apply to files only".
  • Enter 644 into the numeric field.
  • Access the site again and see if it worked.

3. Disable WordPress Plugins

While plugins are useful for making your site into what it is, they have also been known to cause issues such as 403 forbidden errors. The best way to proceed would be to disable all of the plugins you use at the same time, instead of doing each one individually. Through this step, you can find the problem and begin working on the remedy.

  • Access the Hosting account using an FTP and search out the public_html folder.
  • You can instead choose the folder that contains your WordPress installation files.
  • Find the wp-content folder on this page.
  • Find the plugins folder.
  • Rename the plugins folder to something different so it is easier to keep tabs on, such as "disabled plugins".

After all of the plugins have been disabled, try to get onto the site again. If it fixed the 403 forbidden error message, the source of the problem is indeed a plugin. This time, you can deactivate the plugins one by one to diagnose which one is causing the error. 

After you have located the culprit, you can install a new plugin with similar functionality or check for newer updates that might fix the issue.

If none of the listed steps worked for you, you will need to contact the hosting provider to have them help you resolve the issue. It is important to note that if you have recently transferred your site from one host to another, and did not alter the nameservers, the domain name might still be leading the access to the old web host. 

Of course, when they cancel your account, you will get a 403 forbidden error when trying to access the page.

403 forbidden error messages can be frustrating, but they can be just as easy to resolve. No matter what the cause of the error message, there are steps you can take to fix the source and get things working well again. 

In this article, we've outlined detailed steps that should help you to find and fix whatever faults are causing the 403 forbidden error message. By following these guidelines, you should be able to resolve the issue quickly and efficiently. If you are still having trouble after trying the steps in this article, reach out to your web host to figure out how to proceed further, or if you know any other suggestions or fixes you can suggest them via below listed comment box.

People are also reading:

Antoniy Yushkevych

Antoniy Yushkevych

Master of word when it comes to technology, internet and privacy. I'm also your usual guy that always aims for the best result and takes a skateboard to work. If you need me, you will find me at the office's Counter-Strike championships on Fridays or at a.yushkevych@monovm.com