{"id":10347,"date":"2015-12-30T09:33:00","date_gmt":"2015-12-30T07:33:00","guid":{"rendered":"https:\/\/hetzner.co.za\/help-centre\/?p=10347"},"modified":"2025-03-25T09:13:23","modified_gmt":"2025-03-25T07:13:23","slug":"htaccess-explained","status":"publish","type":"post","link":"https:\/\/xneelo.co.za\/help-centre\/website\/htaccess-explained\/","title":{"rendered":".htaccess Explained"},"content":{"rendered":"<h2>What is a .htaccess file?<\/h2>\n<p>A <b>.htaccess<\/b> file is a simple ASCII file (text file), which can be created through a text editor like NotePad or SimpleText. It provides a way to make configuration changes to your website, including: password-protecting folders, automatically redirecting users to different websites or locations on the current site, custom error pages, changing file extensions, banning users with certain IP addresses, only allowing users with certain IP addresses, stopping directory listings and using a different file as the index file.<\/p>\n<p>Traditionally you would place a <b>.htaccess<\/b> file in the root of your public_html (Full path: \/usr\/www\/users\/ftp-username), however, the location of the file is dependent on what you want to achieve. If placed in the root of the public_html the .htaccess file will have effect on your entire site. You can also place the .htaccess file in subdirectories, in which case the file will only affect files under that subdirectory.<\/p>\n<p>The .htaccess file can be created on the server while logged in via Telnet, SSH or created locally on your own machine and then uploaded via FTP.<\/p>\n<p>There are a variety of tools available in your control panel (<a title=\"Index Manager\" href=\"https:\/\/xneelo.co.za\/help-centre\/control-panel\/the-index-manager-tool\/\" target=\"_blank\" rel=\"noopener\">Index Manager<\/a>, <a title=\"Protect Directory\" href=\"https:\/\/xneelo.co.za\/help-centre\/website\/protect-directory-tool\/\" target=\"_blank\" rel=\"noopener\">Protect Directory<\/a>, <a title=\"Redirect\" href=\"https:\/\/xneelo.co.za\/help-centre\/control-panel\/how-to-set-up-web-redirects-via-the-control-panel\/\" target=\"_blank\" rel=\"noopener\">Redirect<\/a>) which assist in the creation and management of .htaccess files.<\/p>\n","protected":false,"plain":"<h2>What is a .htaccess file?<\/h2>\r\nA <b>.htaccess<\/b> file is a simple ASCII file (text file), which can be created through a text editor like NotePad or SimpleText. It provides a way to make configuration changes to your website, including: password-protecting folders, automatically redirecting users to different websites or locations on the current site, custom error pages, changing file extensions, banning users with certain IP addresses, only allowing users with certain IP addresses, stopping directory listings and using a different file as the index file.\r\n\r\nTraditionally you would place a <b>.htaccess<\/b> file in the root of your public_html (Full path: \/usr\/www\/users\/ftp-username), however, the location of the file is dependent on what you want to achieve. If placed in the root of the public_html the .htaccess file will have effect on your entire site. You can also place the .htaccess file in subdirectories, in which case the file will only affect files under that subdirectory.\r\n\r\nThe .htaccess file can be created on the server while logged in via Telnet, SSH or created locally on your own machine and then uploaded via FTP.\r\n\r\nThere are a variety of tools available in your control panel (<a title=\"Index Manager\" href=\"https:\/\/xneelo.co.za\/help-centre\/control-panel\/the-index-manager-tool\/\" target=\"_blank\" rel=\"noopener\">Index Manager<\/a>, <a title=\"Protect Directory\" href=\"https:\/\/xneelo.co.za\/help-centre\/website\/protect-directory-tool\/\" target=\"_blank\" rel=\"noopener\">Protect Directory<\/a>, <a title=\"Redirect\" href=\"https:\/\/xneelo.co.za\/help-centre\/control-panel\/how-to-set-up-web-redirects-via-the-control-panel\/\" target=\"_blank\" rel=\"noopener\">Redirect<\/a>) which assist in the creation and management of .htaccess files."},"excerpt":{"rendered":"<p>A .htaccess file provides a way to make configuration changes on a per-directory basis. It&#8217;s an ASCII file, created through a text editor like NotePad.<\/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":[17003,11262],"topics":[],"class_list":["post-10347","post","type-post","status-publish","format-standard","hentry","category-website","tag-redirect","tag-htaccess"],"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":17003,"name":"redirect","slug":"redirect","term_group":0,"term_taxonomy_id":17003,"taxonomy":"post_tag","description":"","parent":0,"count":3,"filter":"raw","term_order":"2439"},{"term_id":11262,"name":"htaccess","slug":"htaccess","term_group":0,"term_taxonomy_id":11262,"taxonomy":"post_tag","description":"","parent":0,"count":3,"filter":"raw","term_order":"2600"}]},"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\/10347","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=10347"}],"version-history":[{"count":0,"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/posts\/10347\/revisions"}],"wp:attachment":[{"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/media?parent=10347"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/categories?post=10347"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/tags?post=10347"},{"taxonomy":"topics","embeddable":true,"href":"https:\/\/xneelo.co.za\/help-centre\/wp-json\/wp\/v2\/topics?post=10347"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}