{"id":20449,"date":"2017-12-13T16:09:34","date_gmt":"2017-12-13T14:09:34","guid":{"rendered":"https:\/\/hetzner.co.za\/help-centre\/?p=20449"},"modified":"2025-03-24T16:02:33","modified_gmt":"2025-03-24T14:02:33","slug":"open_basedir-error","status":"publish","type":"post","link":"https:\/\/xneelo.co.za\/help-centre\/website\/open_basedir-error\/","title":{"rendered":"What is the open_basedir error?"},"content":{"rendered":"<h2><span style=\"font-weight: 400;\">What is open_basedir?<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">It is a restriction to prevent a hosting package user from accessing any paths on the server that are not authorised, such as the paths to other domains on shared web servers, or to access the hosting software.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">The <\/span><b>open_basedir<\/b><span style=\"font-weight: 400;\"> function defines the locations or paths from which PHP is allowed to access files using functions like fopen() and gzopen(). If a file is outside of the paths defined by open_basedir, PHP will refuse to open it. <\/span><\/p>\n<h2><span style=\"font-weight: 400;\">Why am I getting this error?<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">In most cases, this error occurs when your site has been transferred from a previous host that uses Cpanel, and the relevant file paths have not been updated to reflect the correct file path on our servers.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">All website content needs to be placed in the <\/span><b>public_html<\/b><span style=\"font-weight: 400;\"> folder within the home directory, rather than directly into the home directory.<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">What are the correct file paths?<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">Full path to the <\/span><b>FTP Home directory<\/b><span style=\"font-weight: 400;\"> (default directory displayed when connecting via FTP) is:<\/span><\/p>\n<pre><span style=\"font-weight: 400;\">\/usr\/home\/FTP_USERNAME\/<\/span><\/pre>\n<p><span style=\"font-weight: 400;\">Full path to the <\/span><b>Public_html<\/b><span style=\"font-weight: 400;\"> directory (where all web accessible files need to reside) is:<\/span><\/p>\n<pre><span style=\"font-weight: 400;\">\/usr\/www\/users\/FTP_USERNAME\/<\/span><\/pre>\n<p>Note: The full file\/absolute paths apply to both <a href=\"https:\/\/xneelo.co.za\/web-hosting\/\" target=\"_blank\" rel=\"noopener\">Web Hosting<\/a> and <a href=\"https:\/\/xneelo.co.za\/help-centre\/products-and-services\/managed-hosting\/\" target=\"_blank\" rel=\"noopener\">Managed Servers<\/a><\/p>\n","protected":false,"plain":"<h2><span >What is open_basedir?<\/span><\/h2>\r\n<span >It is a restriction to prevent a hosting package user from accessing any paths on the server that are not authorised, such as the paths to other domains on shared web servers, or to access the hosting software.<\/span>\r\n\r\n<span >The <\/span><b>open_basedir<\/b><span > function defines the locations or paths from which PHP is allowed to access files using functions like fopen() and gzopen(). If a file is outside of the paths defined by open_basedir, PHP will refuse to open it. <\/span>\r\n<h2><span >Why am I getting this error?<\/span><\/h2>\r\n<span >In most cases, this error occurs when your site has been transferred from a previous host that uses Cpanel, and the relevant file paths have not been updated to reflect the correct file path on our servers.<\/span>\r\n\r\n<span >All website content needs to be placed in the <\/span><b>public_html<\/b><span > folder within the home directory, rather than directly into the home directory.<\/span>\r\n<h2><span >What are the correct file paths?<\/span><\/h2>\r\n<span >Full path to the <\/span><b>FTP Home directory<\/b><span > (default directory displayed when connecting via FTP) is:<\/span>\r\n<pre><span >\/usr\/home\/FTP_USERNAME\/<\/span><\/pre>\r\n<span >Full path to the <\/span><b>Public_html<\/b><span > directory (where all web accessible files need to reside) is:<\/span>\r\n<pre><span >\/usr\/www\/users\/FTP_USERNAME\/<\/span><\/pre>\r\nNote: The full file\/absolute paths apply to both <a href=\"https:\/\/xneelo.co.za\/web-hosting\/\" target=\"_blank\" rel=\"noopener\">Web Hosting<\/a> and <a href=\"https:\/\/xneelo.co.za\/help-centre\/products-and-services\/managed-hosting\/\" target=\"_blank\" rel=\"noopener\">Managed Servers<\/a>"},"excerpt":{"rendered":"<p>This a restriction to prevent a user from accessing paths on the server that are not authorised, such as when webcontent has been uploaded incorrectly.<\/p>\n","protected":false},"author":7,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"lsx_disable_title":"0","_relevanssi_hide_post":"","_relevanssi_hide_content":"","_relevanssi_pin_for_all":"","_relevanssi_pin_keywords":"","_relevanssi_unpin_keywords":"","_relevanssi_related_keywords":"","_relevanssi_related_include_ids":"","_relevanssi_related_exclude_ids":"","_relevanssi_related_no_append":"","_relevanssi_related_not_related":"","_relevanssi_related_posts":"","_relevanssi_noindex_reason":"","footnotes":""},"categories":[166],"tags":[9923,9925,9927],"topics":[10463],"class_list":["post-20449","post","type-post","status-publish","format-standard","hentry","category-website","tag-open-base-dir","tag-openbasedir","tag-open_basedir","topics-website-problems"],"acf":[],"additional_meta":{"category_title":[{"term_id":166,"name":"Website","slug":"website","term_group":0,"term_taxonomy_id":166,"taxonomy":"category","description":"About your Website(s)","parent":0,"count":169,"filter":"raw","term_order":"120","cat_ID":166,"category_count":169,"category_description":"About your Website(s)","cat_name":"Website","category_nicename":"website","category_parent":0}],"tag_title":[{"term_id":9923,"name":"open base dir","slug":"open-base-dir","term_group":0,"term_taxonomy_id":9923,"taxonomy":"post_tag","description":"","parent":0,"count":1,"filter":"raw","term_order":"2812"},{"term_id":9925,"name":"openbasedir","slug":"openbasedir","term_group":0,"term_taxonomy_id":9925,"taxonomy":"post_tag","description":"","parent":0,"count":1,"filter":"raw","term_order":"2836"},{"term_id":9927,"name":"open_basedir","slug":"open_basedir","term_group":0,"term_taxonomy_id":9927,"taxonomy":"post_tag","description":"","parent":0,"count":1,"filter":"raw","term_order":"2858"}]},"featured_image_src":null,"author_info":{"display_name":"marketing","author_link":"https:\/\/xneelo.co.za\/help-centre\/author\/marketing\/","author_avatar":"https:\/\/secure.gravatar.com\/avatar\/a6ea315e112423b2b955cb020fbce2b0835956c6ad85ff0f13f1db298977eaaa?s=96&d=mm&r=g"},"_links":{"self":[{"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/posts\/20449","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/users\/7"}],"replies":[{"embeddable":true,"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/comments?post=20449"}],"version-history":[{"count":0,"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/posts\/20449\/revisions"}],"wp:attachment":[{"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/media?parent=20449"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/categories?post=20449"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/tags?post=20449"},{"taxonomy":"topics","embeddable":true,"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/topics?post=20449"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}