{"id":977,"date":"2022-02-11T13:02:24","date_gmt":"2022-02-11T13:02:24","guid":{"rendered":"https:\/\/blog.hostinger.io\/support\/2022\/02\/11\/5973000-how-to-open-the-website-s-root-directory-via-ssh-in-hostinger\/"},"modified":"2026-08-10T06:16:37","modified_gmt":"2026-08-10T06:16:37","slug":"5973000-how-to-open-the-website-s-root-directory-via-ssh-in-hostinger","status":"publish","type":"post","link":"https:\/\/www.hostinger.com\/support\/5973000-how-to-open-the-website-s-root-directory-via-ssh-in-hostinger\/","title":{"rendered":"How to open the website\u2019s root directory via SSH in Hostinger"},"content":{"rendered":"<p>Open your website&rsquo;s root directory via SSH in Hostinger to work directly with your site&rsquo;s files from the command line. The root directory is where your website&rsquo;s files are stored, and by default, this folder is public_html.<\/p><h3>Before you start<\/h3><ul>\n<li><b><a class=\"intercom-content-link\" href=\"https:\/\/www.hostinger.com\/support\/1583494-what-is-the-path-to-your-website-s-root-home-directory-and-how-to-change-it-in-hostinger\/\" target=\"_blank\" rel=\"noopener\">Check the home root path<\/a> <\/b>and <b>copy<\/b> it<\/li>\n<li><b><a class=\"intercom-content-link\" href=\"https:\/\/www.hostinger.com\/support\/1583245-how-to-connect-to-a-hosting-plan-via-ssh-in-hostinger\/\" target=\"_blank\" rel=\"noopener\">Connect to your account using SSH<\/a><\/b><\/li>\n<\/ul><h2 id=\"h-navigate-to-your-root-directory\">Navigate to your root directory<\/h2><p class=\"no-margin\">Once connected to SSH, run the following command:<\/p><pre><code>cd \/home\/u123456789\/domains\/domain.tld\/public_html<\/code><\/pre><p class=\"no-margin\">Replace<b>\/home\/u123456789\/domains\/domain.tld\/public_html<\/b> with the value of the root folder path which you copied.<\/p><p class=\"no-margin\">That&rsquo;s it! You can start working with your website files.<\/p><div class=\"intercom-interblocks-callout\" style=\"background-color: #e3e7fa80;border-color: #334bfa33\">See <a href=\"https:\/\/www.hostinger.com\/support\/5822386-common-ssh-commands-at-hostinger\/\">common SSH commands at Hostinger<\/a> for other useful commands once you&rsquo;re in.<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Locating and reaching the root directory of your website using SSH<\/p>\n","protected":false},"author":581,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"include_on_kodee":true,"footnotes":""},"categories":[235],"tags":[],"class_list":["post-977","post","type-post","status-publish","format-standard","hentry","category-ssh-connection-and-ssh-keys"],"hreflangs":[{"locale":"en-US","link":"https:\/\/www.hostinger.com\/support\/5973000-how-to-open-the-website-s-root-directory-via-ssh-in-hostinger\/","default":1},{"locale":"es-ES","link":"https:\/\/www.hostinger.com\/es\/support\/5973000-como-abrir-el-directorio-raiz-del-sitio-web-a-traves-de-ssh-en-hostinger\/","default":0},{"locale":"fr-FR","link":"https:\/\/www.hostinger.com\/fr\/support\/5973000-comment-ouvrir-le-repertoire-racine-d-un-site-web-via-ssh-chez-hostinger\/","default":0},{"locale":"id-ID","link":"https:\/\/www.hostinger.com\/id\/support\/5973000-cara-menemukan-direktori-root-dengan-ssh-di-hostinger\/","default":0},{"locale":"pt-BR","link":"https:\/\/www.hostinger.com\/br\/support\/5973000-como-abrir-o-diretorio-raiz-do-site-via-ssh-no-hostinger\/","default":0},{"locale":"uk-UA","link":"https:\/\/www.hostinger.com\/ua\/support\/5973000-----\/","default":0}],"include_on_kodee":true,"_links":{"self":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/977","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/users\/581"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/comments?post=977"}],"version-history":[{"count":2,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/977\/revisions"}],"predecessor-version":[{"id":14973,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/977\/revisions\/14973"}],"wp:attachment":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/media?parent=977"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/categories?post=977"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/tags?post=977"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}