{"id":8799,"date":"2019-12-27T11:04:21","date_gmt":"2019-12-27T11:04:21","guid":{"rendered":"https:\/\/www.milesweb.in\/hosting-faqs\/?p=8799"},"modified":"2019-12-27T11:04:21","modified_gmt":"2019-12-27T11:04:21","slug":"steps-to-set-wordpress-to-ignore-a-file-path","status":"publish","type":"post","link":"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/","title":{"rendered":"Steps to Set WordPress to Ignore a File Path"},"content":{"rendered":"<p>Sometimes, it is important to allow access to a file or directory but don\u2019t require a sub domain. For example, when you upload a file or folder to your public_html directory, but WordPress shows a 404 error while attempting to access its file path. In such cases, you can create a rewrite condition within your .htaccess file to force your WordPress website to ignore the file path of that file. With this a file \u2013 e.g. domain.com\/file.html \u2013 will get displayed as is instead of embedded as part of the parent WordPress website.<\/p>\n<h3>Steps to Edit WordPress to Ignore a File Path<\/h3>\n<ol>\n<li>Login to your account via SSH or cPanel File Editor, navigate to your WordPress directory.<\/li>\n<li>Open your website with .htaccess file.<\/li>\n<li>Check below the default WordPress .htaccess file:\n<pre class=\"lang:default decode:true \"># BEGIN WordPress\r\n\r\nRewriteEngine On\r\nRewriteBase \/\r\nRewriteRule ^index\\.php$ \u2013 [L]\r\nRewriteCond %{REQUEST_FILENAME} !-f\r\nRewriteCond %{REQUEST_FILENAME} !-d\r\nRewriteRule . \/index.php [L]\r\n\r\n# END WordPress<\/pre>\n<p>Add the below code above the RewriteCond lines, replacing file with the file path to your saved files:<\/p>\n<pre class=\"lang:default decode:true \">RewriteCond $1 !^(\/file)<\/pre>\n<\/li>\n<li>Then save your changes.<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>Sometimes, it is important to allow access to a file or directory but don\u2019t require a sub domain. For example, when you upload a file or folder to your public_html directory, but WordPress shows a 404 error while attempting to access its file path. In such cases, you can create a rewrite condition within your [&hellip;]<\/p>\n","protected":false},"author":16,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[17],"tags":[1199,78,178],"class_list":["post-8799","post","type-post","status-publish","format-standard","placeholder-for-hentry","category-wordpress-faq","tag-ignore-a-file-path-in-wordpress","tag-wordpress-2","tag-wordpress-website"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Steps to Set WordPress to Ignore a File Path<\/title>\n<meta name=\"description\" content=\"The article describes the steps to set WordPress to ignore a file path.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Steps to Set WordPress to Ignore a File Path\" \/>\n<meta property=\"og:description\" content=\"The article describes the steps to set WordPress to ignore a file path.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/\" \/>\n<meta property=\"og:site_name\" content=\"Web Hosting FAQs by MilesWeb\" \/>\n<meta property=\"article:published_time\" content=\"2019-12-27T11:04:21+00:00\" \/>\n<meta name=\"author\" content=\"Pallavi Godse\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Pallavi Godse\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/\"},\"author\":{\"name\":\"Pallavi Godse\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/7e3952607fa9eb4e82fea9f7cad9c945\"},\"headline\":\"Steps to Set WordPress to Ignore a File Path\",\"datePublished\":\"2019-12-27T11:04:21+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/\"},\"wordCount\":164,\"commentCount\":0,\"keywords\":[\"Ignore a file path in WordPress\",\"WordPress\",\"WordPress website\"],\"articleSection\":[\"WordPress FAQ\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/\",\"url\":\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/\",\"name\":\"Steps to Set WordPress to Ignore a File Path\",\"isPartOf\":{\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#website\"},\"datePublished\":\"2019-12-27T11:04:21+00:00\",\"author\":{\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/7e3952607fa9eb4e82fea9f7cad9c945\"},\"description\":\"The article describes the steps to set WordPress to ignore a file path.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.milesweb.in\/hosting-faqs\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Steps to Set WordPress to Ignore a File Path\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#website\",\"url\":\"https:\/\/www.milesweb.in\/hosting-faqs\/\",\"name\":\"Web Hosting FAQs by MilesWeb\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.milesweb.in\/hosting-faqs\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/7e3952607fa9eb4e82fea9f7cad9c945\",\"name\":\"Pallavi Godse\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/3602d0ac1ab89332aea8205dcf474af4ff4eb319cfd584544038908cd5e4c966?s=96&d=blank&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/3602d0ac1ab89332aea8205dcf474af4ff4eb319cfd584544038908cd5e4c966?s=96&d=blank&r=g\",\"caption\":\"Pallavi Godse\"},\"description\":\"Pallavi is a Digital Marketing Executive at MilesWeb and has an experience of over 4 years in content development. She is interested in writing engaging content on business, technology, web hosting and other topics related to information technology.\",\"sameAs\":[\"https:\/\/www.milesweb.in\"],\"url\":\"https:\/\/www.milesweb.in\/hosting-faqs\/author\/pallavi\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Steps to Set WordPress to Ignore a File Path","description":"The article describes the steps to set WordPress to ignore a file path.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/","og_locale":"en_US","og_type":"article","og_title":"Steps to Set WordPress to Ignore a File Path","og_description":"The article describes the steps to set WordPress to ignore a file path.","og_url":"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/","og_site_name":"Web Hosting FAQs by MilesWeb","article_published_time":"2019-12-27T11:04:21+00:00","author":"Pallavi Godse","twitter_misc":{"Written by":"Pallavi Godse","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/#article","isPartOf":{"@id":"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/"},"author":{"name":"Pallavi Godse","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/7e3952607fa9eb4e82fea9f7cad9c945"},"headline":"Steps to Set WordPress to Ignore a File Path","datePublished":"2019-12-27T11:04:21+00:00","mainEntityOfPage":{"@id":"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/"},"wordCount":164,"commentCount":0,"keywords":["Ignore a file path in WordPress","WordPress","WordPress website"],"articleSection":["WordPress FAQ"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/","url":"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/","name":"Steps to Set WordPress to Ignore a File Path","isPartOf":{"@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#website"},"datePublished":"2019-12-27T11:04:21+00:00","author":{"@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/7e3952607fa9eb4e82fea9f7cad9c945"},"description":"The article describes the steps to set WordPress to ignore a file path.","breadcrumb":{"@id":"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/steps-to-set-wordpress-to-ignore-a-file-path\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.milesweb.in\/hosting-faqs\/"},{"@type":"ListItem","position":2,"name":"Steps to Set WordPress to Ignore a File Path"}]},{"@type":"WebSite","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#website","url":"https:\/\/www.milesweb.in\/hosting-faqs\/","name":"Web Hosting FAQs by MilesWeb","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.milesweb.in\/hosting-faqs\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/7e3952607fa9eb4e82fea9f7cad9c945","name":"Pallavi Godse","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/3602d0ac1ab89332aea8205dcf474af4ff4eb319cfd584544038908cd5e4c966?s=96&d=blank&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/3602d0ac1ab89332aea8205dcf474af4ff4eb319cfd584544038908cd5e4c966?s=96&d=blank&r=g","caption":"Pallavi Godse"},"description":"Pallavi is a Digital Marketing Executive at MilesWeb and has an experience of over 4 years in content development. She is interested in writing engaging content on business, technology, web hosting and other topics related to information technology.","sameAs":["https:\/\/www.milesweb.in"],"url":"https:\/\/www.milesweb.in\/hosting-faqs\/author\/pallavi\/"}]}},"_links":{"self":[{"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/posts\/8799","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/users\/16"}],"replies":[{"embeddable":true,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/comments?post=8799"}],"version-history":[{"count":2,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/posts\/8799\/revisions"}],"predecessor-version":[{"id":8801,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/posts\/8799\/revisions\/8801"}],"wp:attachment":[{"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/media?parent=8799"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/categories?post=8799"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/tags?post=8799"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}