What is the document root?

During installation of web application and software, you might have read technical instructions that mentions "document root". For example, it might have asked you to put a file in "document root", etc.

The "document root" refers to a folder on your web server that is set to be "publicly available". This is where you would put file for your public website, for example.

Different webhosts may have different name for this folder that is the "document root". Some name this document root folder as "public_html", "www", "htdocs", "httpdocs", "html", or "web". Or some host may not have a folder at all.

If you are not sure, you can always upload a test file (named "test.html" with the content "Hello" for example) to the "document root" and see if you can view the file's content via the browser at the url http://www.example.com/test.html where example.com is your domain name. If yes, then you have found the document root.