robots.txt static System Administrator Jahia 7.3 Jahia 8 Legacy

Cannot access robots.txt

Question

A static file robotos.txt  is present in tomcat/webapps/ROOT but the URL https://www.mydomain.com/robots.txt returns a 404.

Answer

You will need to add the following line in your jahia.properties

seoReservedUrlPrefixes=robots.txt

And then restart Jahia. If you need to allow several files, then separate the filenames with a coma.

seoReservedUrlPrefixes=robots.txt,sitemap.xml