I cannot update the favicon in react boilerplate.
I replaced the file in images/app/favicon.ico with my own file, but I'm still seeing the old icon show up.
I cleared my browser cache, ran npm run build:clean
, and npm run build
.
Can't get my new favicon to render. Please advise how to update the favicon.
You will have to delete your cache from your browser, close your browser and reopen it. That should fix it. I don't believe your favicons will get refreshed on your favorites until you revisit that page, and assuming that you had previously cleared your browsers cache.
For the most part it seems like most SEOs said it takes around 24 hours, sometimes less. The guidelines specifically say "Google will look for and update your favicon whenever it crawls your home page.
The problem is that the browser is holding onto the old image in the cache and not updating it.
To solve this problem update the favicon url to %PUBLIC_URL%/favicon.ico?v=2
The ?v=2
at the end will force the browser to refresh the favicon.
See How do I force a favicon refresh? for more details.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With