Nginx wont serve updated web content

Posted March 6, 2020 423 views

Hi! I added new updated files for my website. I restarted Nginx and it still showing the old files and newer ones are missing or still didn’t update.

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.

Submit an Answer
1 answer

Hi there @SephiaSky,

I think that you might have to delete your default index file and change it with your own index.html file.

Can you share your Nginx configuration here and the content of your /var/www/html folder? To do that you can run:

  • cat /etc/nginx/sites-enabled/default

And to check the content of your html folder you can run:

ls -lah /var/www/html


  • Thanks for the reply, Bobby! I just view my website again. And, it seems to be updated now. Just what I expect it to be but it wasn’t like that earlier. Do you know why is there is a delay?

    • Hi there @SephiaSky,

      This is most likely your browser’s cache. What you could do next time is to refresh the page a few times by pressing CTRL+F5, that way the browser would be forced to reload all of its caches for the specific website.

      Hope that this helps!