{"id":636,"date":"2023-12-19T07:52:46","date_gmt":"2023-12-19T07:52:46","guid":{"rendered":"https:\/\/linuxresellerwebhosting.in\/blog\/?p=636"},"modified":"2023-12-19T08:20:52","modified_gmt":"2023-12-19T08:20:52","slug":"what-is-403-forbidden-error","status":"publish","type":"post","link":"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/","title":{"rendered":"What is 403 Forbidden Error?"},"content":{"rendered":"<p>This is a HTTP error occurred due to denied access to any particular file or folder that trying to access.And in other way,it is an HTTP status code,(i.e) that accessing the page or resource you were trying to reach is absolutely forbidden due to some reason.<br \/>\nHTTP 403 forbidden Error is a general issue indicating that the web server received and understood your request, but cannot take a further action to response it.It\u2019s common to meet this problem when surfing on the Internet or running a website 403 Forbidden is a simple HTTP status code appeared when you cannot successfully access a web page. It shows that you don\u2019t have the permission to access on the server.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Appearance_of_403_Error\"><\/span>Appearance of 403 Error:<span class=\"ez-toc-section-end\"><\/span><\/h3><div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 ez-toc-wrap-left counter-hierarchy ez-toc-counter ez-toc-light-blue ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<span class=\"ez-toc-title-toggle\"><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Appearance_of_403_Error\" >Appearance of 403 Error:<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Causes_for_403_forbidden_error\" >Causes for 403 forbidden error:<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Fixing_the_HTTP_403_Forbidden_Error\" >Fixing the HTTP 403 Forbidden Error:<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#AllowDeny_Access_to_Your_Website_Files_using_htaccess\" >Allow\/Deny Access to Your Website Files using .htaccess.<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Updates_in_htaccess_file\" >Updates in .htaccess file.<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Deny_access_to_entire_website_from_all_IPs_except_from_one_1111\" >Deny access to entire website from all IP&#8217;s except from one (1.1.1.1)<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Deny_access_to_all_html_files_from_all_IPS_except_1111\" >Deny access to all .html files from all IPS except 1.1.1.1<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Deny_access_to_all_html_htm_txt_jpg_jpeg_files_from_all_IPS_except_1111\" >Deny access to all .html, .htm, .txt, .jpg, .jpeg files from all IPS except 1.1.1.1<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Allow_access_from_everywhere_except_from_one_IP\" >Allow access from everywhere except from one IP<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Permissions_of_Files_or_Directory\" >Permissions of Files or Directory:<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Check_and_Modify_the_File_Permissions\" >Check and Modify the File Permissions.<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-12\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Permissions_Explanation\" >Permissions Explanation<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-13\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Clear_Cache_and_Cookies\" >Clear Cache and Cookies:<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-14\" href=\"https:\/\/linuxresellerwebhosting.in\/blog\/what-is-403-forbidden-error\/#Deactivate_Your_Plugins_and_Themes\" >Deactivate Your Plugins and Themes:<\/a><\/li><\/ul><\/nav><\/div>\n\n<p>Different web browsers will display 403 Forbidden Error in different ways.<\/p>\n<p>The following are the few common browser errors.<\/p>\n<p><strong>\u201c403 Forbidden\u201d<\/strong><\/p>\n<p><strong>\u201cForbidden: You don&#8217;t have permission to access file\/folder on this server.<\/strong><\/p>\n<p><strong>\u201cHTTP 403\u201d<\/strong><\/p>\n<p>&nbsp;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-478 size-full\" src=\"https:\/\/coimbatorewebhosting.com\/blog\/wp-content\/uploads\/2017\/07\/forbidden.jpg\" alt=\"403 forbidden\" width=\"1131\" height=\"433\" \/><\/p>\n<h3><span class=\"ez-toc-section\" id=\"Causes_for_403_forbidden_error\"><\/span>Causes for 403 forbidden error:<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>The forbidden error 403 is caused by corrupt of .htaccess file.<\/p>\n<p>Permissions of files or directory.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Fixing_the_HTTP_403_Forbidden_Error\"><\/span>Fixing the HTTP 403 Forbidden Error:<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>The 403 Forbidden Error indicates that your website files have incorrect permissions. Every file\/directory of your website have an individual settings that controls who is allowed to read, write,and execute specified file\/directory.When you create new file or folder, default permissions are automatically applied which can be changed later on.<\/p>\n<p>The HTTP 403 Forbidden error is caused by limited access to a web <a href=\"https:\/\/www.squarebrothers.com\/domain-registration-india\/\" target=\"_blank\" rel=\"noopener\">domain<\/a> or directory. Administrators can limit access to a web domain&#8217;s directory by removing the anonymous user or requiring a password to view the content of the location.<\/p>\n<p>Once permissions are set, browsers to the domain will be able to access and read files normally again.<\/p>\n<p>The following steps will fix the above 403 HTTP forbidden error,<\/p>\n<ul>\n<li>Fix the Corrupted .htaccess File.<\/li>\n<li>Check and Modify the File Permissions.<\/li>\n<li>Clear Cache and Cookies.<\/li>\n<li>Deactivate Your Plugins and Themes.<\/li>\n<\/ul>\n<h3 align=\"justify\"><span class=\"ez-toc-section\" id=\"AllowDeny_Access_to_Your_Website_Files_using_htaccess\"><\/span><strong>Allow\/Deny Access to Your Website Files using .htaccess.<\/strong><span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Web pages are nothing but the files which you are hosted in your web server. There are many possibilities to restrict the users to access the URL&#8217;S of your website. You can also restrict the end user from accessing the website and can limit access to few files\/folders instead of giving full permissions.<\/p>\n<p>There are few options which can be done using .htaccess<\/p>\n<ul>\n<li>Need to deny from everywhere expect from where you access your website files. It will shoot 403 forbidden error when anyone access the website from other IP&#8217;s.<\/li>\n<li>Deny all the IPS with a few exceptions from viewing your website and website files. Here you can allow few IP&#8217;s and gives permission to access.<\/li>\n<li>Allow all IPS to view your website and website files. This is the default action for every website.<\/li>\n<li>Deny all IP&#8217;s from viewing &#8220;.jpeg&#8221; files on a website. It disallows .jpeg files to access from elsewhere.<\/li>\n<\/ul>\n<p>Few websites which were authenticated by default and any end user try to access with no password it will throw 403 Forbidden Error. Basically, these settings can be updated in .htaccess or else you can set this from your cPanel too.<\/p>\n<h4><span class=\"ez-toc-section\" id=\"Updates_in_htaccess_file\"><\/span>Updates in .htaccess file.<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<h4><span class=\"ez-toc-section\" id=\"Deny_access_to_entire_website_from_all_IPs_except_from_one_1111\"><\/span>Deny access to entire website from all IP&#8217;s except from one (1.1.1.1)<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<pre>Allow from 1.1.1.1\r\nDeny from all<\/pre>\n<h4><span class=\"ez-toc-section\" id=\"Deny_access_to_all_html_files_from_all_IPS_except_1111\"><\/span>Deny access to all .html files from all IPS except 1.1.1.1<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<pre>&lt;FilesMatch \".html$\"&gt;\r\nAllow from 1.1.1.1\r\nDeny from all\r\n&lt;\/FilesMatch&gt;<\/pre>\n<h4><span class=\"ez-toc-section\" id=\"Deny_access_to_all_html_htm_txt_jpg_jpeg_files_from_all_IPS_except_1111\"><\/span>Deny access to all .html, .htm, .txt, .jpg, .jpeg files from all IPS except 1.1.1.1<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<pre>&lt;FilesMatch \".(html|htm|txt|jpg|jpeg)$\"&gt;\r\nAllow from 1.1.1.1\r\nDeny from all\r\n&lt;\/FilesMatch&gt;<\/pre>\n<h4><span class=\"ez-toc-section\" id=\"Allow_access_from_everywhere_except_from_one_IP\"><\/span>Allow access from everywhere except from one IP<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<pre>Deny from 1.1.1.1<\/pre>\n<p>We can done by using this in control panel and the image is shown below,<br \/>\nIn that control panel go to the file manager and click public_html \u00a0there we can find the folder named .htaccess.<br \/>\nBy editing the file (follow the above steps) we can solve the error.<\/p>\n<p>&nbsp;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone\" src=\"https:\/\/www.coimbatorewebhosting.com\/blog\/wp-content\/uploads\/2017\/07\/htaccess.jpg\" alt=\"403\" width=\"698\" height=\"376\" \/><\/p>\n<h3><span class=\"ez-toc-section\" id=\"Permissions_of_Files_or_Directory\"><\/span>Permissions of Files or Directory:<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h3><span class=\"ez-toc-section\" id=\"Check_and_Modify_the_File_Permissions\"><\/span>Check and Modify the File Permissions.<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>There are three types of permissions<br \/>\nRead<br \/>\nWrite<br \/>\nExecute<br \/>\nFile permissions can be determined and set through FTP client or from cPanel. At cPanel, you would see file permissions in the form of numbers as follows.<\/p>\n<pre>7 ==&gt; Read + Write + Execute\r\n6 ==&gt; Read + Write\r\n5 ==&gt; Read + Execute\r\n4 ==&gt; Read Only\r\n3 ==&gt; Write + Execute\r\n2 ==&gt; Write Only\r\n1 ==&gt; Execute Only\r\n0 ==&gt; Access Denied<\/pre>\n<h3><span class=\"ez-toc-section\" id=\"Permissions_Explanation\"><\/span>Permissions Explanation<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>777 (Not Recommended)<\/p>\n<pre>Owner :: READ(4) + WRITE(2) + EXECUTE(1) ==&gt;7\r\nGroup :: READ(4) + WRITE(2) + EXECUTE(1) ==&gt;7\r\nWorld :: READ(4) + WRITE(2) + EXECUTE(1) ==&gt;7<\/pre>\n<p>755 (Subfolders)<\/p>\n<pre>Owner :: READ(4) + WRITE(2) + EXECUTE(1) ==&gt;7\r\nGroup :: READ(4) + EXECUTE(1) ==&gt;5\r\nWorld :: READ(4) + EXECUTE(1) ==&gt;5<\/pre>\n<p>750 (Public_html)<\/p>\n<pre>Owner :: READ(4) + WRITE(2) + EXECUTE(1) ==&gt;7\r\nGroup :: READ(4) + EXECUTE(1) ==&gt;5\r\nWorld :: 0<\/pre>\n<p>644 (All files)<\/p>\n<pre>Owner :: READ(4) + WRITE(2)==&gt;6\r\nGroup :: READ(4)==&gt;4\r\nWorld :: READ(4)==&gt;4<\/pre>\n<p>444 (Read Only)<\/p>\n<pre>Owner :: READ(4)==&gt;4\r\nGroup :: READ(4)==&gt;4\r\nWorld :: READ(4)==&gt;4<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter\" src=\"https:\/\/www.coimbatorewebhosting.com\/blog\/wp-content\/uploads\/2017\/07\/403-1.jpg\" alt=\"403\" width=\"679\" height=\"243\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter\" src=\"https:\/\/www.coimbatorewebhosting.com\/blog\/wp-content\/uploads\/2017\/07\/403-2.jpg\" alt=\"403\" width=\"280\" height=\"361\" \/><\/p>\n<h3><span class=\"ez-toc-section\" id=\"Clear_Cache_and_Cookies\"><\/span>Clear Cache and Cookies:<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>If we have already fixed this 403 error. However, the error may still exist due to the browser cookies and cache data. In this case, you need to clear them to make sure that your method truly takes effects.<\/p>\n<p>In addition, if your website is powered by a cache plug-in for the performance improvement, you\u2019d better delete all the cached pages and turn off the caching function for a while.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Deactivate_Your_Plugins_and_Themes\"><\/span>Deactivate Your Plugins and Themes:<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Here, you need to know that some compatibility issues and the faulty settings of your plug-ins and themes may also cause the 403 error. In this case, you should deactivate all of them to figure out whether this error lays on this aspect. If the 403 error disappears, you can start the boring task of picking up the real trouble maker.<\/p>\n<p>Here, to deactivate your plug-ins and themes altogether, you simply need to locate your plug-in folder and theme folder using the File Manager or the FTP. After that, you can change their names to anything you like. This way, Word Press cannot find your plug-ins and templates so as to result in the deactivation.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter\" src=\"https:\/\/www.coimbatorewebhosting.com\/blog\/wp-content\/uploads\/2017\/07\/cache.jpg\" alt=\"403\" width=\"683\" height=\"223\" \/><\/p>\n<p>By follow all the above steps we can easily fix the 403 forbidden error.<\/p>\n<p>Thanks for viewed the article.To know more about how to know change RDP port number on windows <a href=\"https:\/\/linuxresellerwebhosting.in\/blog\/how-to-change-rdp-port-number-on-windows\/\">click here<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This is a HTTP error occurred due to denied access to any particular file or folder that trying to access.And<\/p>\n","protected":false},"author":2,"featured_media":641,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"colormag_page_container_layout":"default_layout","colormag_page_sidebar_layout":"default_layout","footnotes":""},"categories":[2,21],"tags":[22,24,25,23],"class_list":["post-636","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux","category-troubleshoot","tag-htacess","tag-allow","tag-deny","tag-forbidden"],"_links":{"self":[{"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/posts\/636","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/comments?post=636"}],"version-history":[{"count":4,"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/posts\/636\/revisions"}],"predecessor-version":[{"id":640,"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/posts\/636\/revisions\/640"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/media\/641"}],"wp:attachment":[{"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/media?parent=636"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/categories?post=636"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/linuxresellerwebhosting.in\/blog\/wp-json\/wp\/v2\/tags?post=636"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}