Report this

What is the reason for this report?

Unable to see var/www/html via SFTP

Posted on September 8, 2015

Hey guys, I created a Ubuntu 14.04 droplet with LAMP. I am able to see the Apache2 Ubuntu page when navigating to the public IP address in browser. However I am unable to see var/www/html via SFTP or even though SSH, hidden or not. Futhermore if I create those folders and dump and index.html file in, it doesn’t load said index.html it still loads the Apache2 Ubuntu page.



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

When you log in you are going to your home folder of the user ~

Do the following

cd /
cd /var/www/

I think I may know what problem you are encountering. When you log in as root via ssh or sftp you start out in the /root directory. Since your web root is /var/www/html you would first need to move up a directory cd .. in an ssh session or by clicking the .. option in most SFTP clients. This will bring you to / and from there you should see the /var/www/html directory structure.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.