Finally after almost three weeks of trial and error, I have reached the promised land. Now that I am here, I notice that my site loads funny. By that I mean the following:

When going to my sites IP address (test environment currently) I get a very generic looking page that states "Index of /" and below that is the craft and public directories. enter image description here

I must add that the Dashboard loads fine: Just when going to the main IP as shown in the picture.
Anyone else encounter this issue?

Have craft installed on a LAMP server, and can provide details if needed.

Thank you and I look forward to hearing back from you all soon. :-)

Thoughts? Thank you for all assistance here!


1 Answer 1


This looks like a problem with your DocumentRoot config option.

If you have access to your Apache VirtualHost configuration, you should append /public to your DocumentRoot.

If you're configuring the host via some kind of control panel (i.e. via your web host), look for an option like "Web Root," and add the same /public path.

So, if your current DocumentRoot was /home/username/website.com, you'd change it to /home/username/website.com/public.

Many hosts will have a DocumentRoot like /var/www/website.com—same deal! Just add /public so it looks like /var/www/website.com/public.

This is just about as good a start as we can get without knowing more about your setup.

Edit: The page you're seeing is what's called an "index," and it's dynamically generated by Apache for folders that don't contain an appropriate script or static file (typically, index.html or index.php)—you'll notice that the public folder of your Craft installation has this file—and that's where all the magic begins!

  • Thank you for this, unfortunately this didn't work for me, made things a bit worse, see edited details above. Commented Mar 8, 2017 at 18:54
  • At the risk of sounding defensive—the above does seem to have fixed the original problem, which was a VirtualHost configuration problem. Now, you're dealing with an entirely unrelated MySQL problem, which is only come to light now that the front-end of your site is accessible. Note that you'll need to visit your site without the /public folder in the URL, since that's now factored into the base URL of the host. Commented Mar 9, 2017 at 16:56
  • No worries, good sir! I am here to learn; and yes, I see now that you did provide the correct answer to solving my original post. My apologies for sounding ungrateful - sincerely. Regarding the /pubic in the URL that is handle with: craftcms.com/support/remove-index.php , correct? Or is there a different article that I should look at? Thank you and my apologies once again. Commented Mar 10, 2017 at 16:09
  • Thanks for pointing out there are two different errors happening here. I will move questions to a new thread and have made your answer the official answer for the original question. Commented Mar 10, 2017 at 19:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.