# Need to clear navigation data to see changes

**URL:** https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415
**Category:** Hosting Support
**Created:** [April 5, 2023, 9:18pm UTC](https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415 "2023-04-05T21:18:50Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![anon20058629](https://forum.infinityfree.com/letter_avatar/anon20058629/32/5_5575768a8748004e209b776fc1b2916d.png) [@anon20058629](https://forum.infinityfree.com/u/anon20058629)
#### Post date: [April 5, 2023, 9:18pm UTC](https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415/1 "2023-04-05T21:18:51Z")

</div>

I’m hosting a website and everytime I change any CSS or JavaScript code, I need to clea navigation data from my browser to see the changes in the live website. Can I fix this somehow?

---

<div class="post-metadata">

### Author: ![Greenreader9](https://forum.infinityfree.com/user_avatar/forum.infinityfree.com/greenreader9/32/22847_2.png) [@Greenreader9](https://forum.infinityfree.com/u/Greenreader9)
#### Post date: [April 5, 2023, 9:31pm UTC](https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415/2 "2023-04-05T21:31:44Z")

</div>

Besides [clearing your cache](https://tinkertechlab.com/webhosting/security/how-to-clear-your-browsers-cache) after every changes, you can just let the browser update on its own.

I would not want to change this behavior, it would just make website load more slowly for you, and you would use more data every time you request a page

---

<div class="post-metadata">

### Author: ![anon96001890](https://forum.infinityfree.com/letter_avatar/anon96001890/32/5_5575768a8748004e209b776fc1b2916d.png) [@anon96001890](https://forum.infinityfree.com/u/anon96001890)
#### Post date: [April 6, 2023, 5:40pm UTC](https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415/3 "2023-04-06T17:40:59Z")

</div>

You can just use Ctrl+F5. This will refresh the page with cleaning cache

---

<div class="post-metadata">

### Author: ![anon20058629](https://forum.infinityfree.com/letter_avatar/anon20058629/32/5_5575768a8748004e209b776fc1b2916d.png) [@anon20058629](https://forum.infinityfree.com/u/anon20058629)
#### Post date: [April 6, 2023, 6:09pm UTC](https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415/4 "2023-04-06T18:09:52Z")

</div>

But whenever I make changes to the website, other people won’t see them until they clean the cache

---

<div class="post-metadata">

### Author: ![anon96001890](https://forum.infinityfree.com/letter_avatar/anon96001890/32/5_5575768a8748004e209b776fc1b2916d.png) [@anon96001890](https://forum.infinityfree.com/u/anon96001890)
#### Post date: [April 6, 2023, 6:29pm UTC](https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415/5 "2023-04-06T18:29:57Z")

</div>

But thats normal

---

<div class="post-metadata">

### Author: ![Greenreader9](https://forum.infinityfree.com/user_avatar/forum.infinityfree.com/greenreader9/32/22847_2.png) [@Greenreader9](https://forum.infinityfree.com/u/Greenreader9)
#### Post date: [April 6, 2023, 9:31pm UTC](https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415/6 "2023-04-06T21:31:00Z")

</div>

Well, they will see the changes when the cache period expires, and that will be totally fine for 99% of your visitors. Most of them won’t visit your site too frequently, so by the time they come back again, the cache period will most likely be expired.

---

<div class="post-metadata">

### Author: ![lovebug](https://forum.infinityfree.com/user_avatar/forum.infinityfree.com/lovebug/32/57624_2.png) [@lovebug](https://forum.infinityfree.com/u/lovebug)
#### Post date: [April 8, 2023, 11:30am UTC](https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415/7 "2023-04-08T11:30:38Z")

</div>

on my website [https://lovebyte.eu.org](https://lovebyte.eu.org) I was having this same issue and the solution I came up with was to rename my index.html page to index.php

then in the head section where I load my css file I used this code

```auto
<link rel='stylesheet' href='/lovebug.css?<?php echo filemtime($_SERVER["DOCUMENT_ROOT"] . "/lovebug.css"); ?>' />

```

what this does is add “?” followed by the file creation time after the css file name which causes the browser to see a new file name when you update the css and the browser will reload and cache the changes

no need to refresh the page, works every time 😃

I havent tried it with javascript files but it’ll probably work ?

---

<div class="post-metadata">

### Author: ![wackyblackie](https://forum.infinityfree.com/user_avatar/forum.infinityfree.com/wackyblackie/32/43350_2.png) [@wackyblackie](https://forum.infinityfree.com/u/wackyblackie)
#### Post date: [April 8, 2023, 2:01pm UTC](https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415/8 "2023-04-08T14:01:43Z")

</div>

Actually it fetches new resources if you add a query string (or it’s supposed to), but the general practice is to add something like that to force it to grab new resources (which sometimes it just doesn’t anyway). IMO adding the file hash to the file name (like webpack does) is a better solution, but it becomes annoying to maintain.

---

<div class="post-metadata">

### Author: ![system](https://infinityfree-forum-uploads.s3.dualstack.eu-central-1.amazonaws.com/original/3X/b/0/b024fd3fa88bae093c9576e55c2c94e33f890206.svg) [@system](https://forum.infinityfree.com/u/system)
#### Post date: [April 15, 2023, 2:01pm UTC](https://forum.infinityfree.com/t/need-to-clear-navigation-data-to-see-changes/74415/9 "2023-04-15T14:01:50Z")

</div>

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
