Upload a website you’ve built

Put an HTML or PHP website online by uploading it as a zip, extracting it into public_html and checking every page loads.

BeginnerAbout 15 minutes8 steps

What you’ll need

  • Your website files on your computer
  • DirectAdmin access

Uploading one zip file and extracting it on the server is far quicker and more reliable than uploading hundreds of files. You don’t need to wait for your domain to connect to do this.

Steps

  1. Step 1: Check your home page file

    Your site’s front page must be called index.html or index.php, all lowercase. Rename it if needed.

  2. Step 2: Zip the contents, not the folder

    Open your site folder, select everything inside it (index.html, css, images...), and compress those items into a zip. This makes the files land directly in public_html.

  3. Step 3: Open public_html

    Open System Info & Files then File Manager and go to domains/yourdomain.co.uk/public_html. Where to upload your website: public_html explained

  4. Step 4: Remove the placeholder

    If there’s a placeholder index.html you didn’t create, delete it so it can’t hide your site. Seeing a default page instead of your website

  5. Step 5: Upload the zip

    Select Upload, add your zip, and wait for it to finish.

  6. Step 6: Extract it

    Select the zip, choose Extract, keep the destination as public_html, and extract. Check index.html now sits directly inside public_html.

  7. Step 7: Delete the zip

    Remove the zip file from the server. It uses disk space and could be downloaded by anyone guessing its name.

  8. Step 8: Test every page

    Once your domain resolves, visit the site in a private window and click through each page, checking images and styles load.

Check it worked

https://yourdomain.co.uk shows your home page, and links, images and stylesheets all load without 404 errors in the browser console.

If something goes wrong

What happensWhat to do
Site appears at yourdomain.co.uk/foldernameYou zipped the folder. Move its contents up into public_html.
Some images or pages 404Linux is case-sensitive; check file name capitals match your links. 404 Not Found: why pages are missing and how to fix it
Unstyled pageCSS paths are wrong. Use paths starting with /, such as /css/style.css.
403 Forbidden on the home pageNo index file in public_html. 403 Forbidden: how to fix it

Following along without an account? Traxio’s free web hosting trial gives you everything this tutorial uses, free for 30 days.

Popular

Tip: press / to search from any pageSee all results