Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why are favicons cached longer?

I would like to know why favicons, unlike images and other resources are stored far longer in cache and seem to be very persistent as well. I'm using Google Chrome, so the question aims this browser, but also browsers in general as I observed this behavior in other browsers, too.

This question (related, not a duplicate) targets the "how to delete them" question. However, I want to understand why favicons seem to be treated so distinctively, whereas my interest in deleting them is rather secondary to irrelevant.

As a web developer, I can simply apply favicon.ico?2 and get a "fresh" one. And the responsibility lies in the provider of an application rather than in the user managing his own cache (or "petting" my application as I like to call it). So this is not my main question.


Why do favicons seem to be more persistent than other resources?

like image 673
bytecode77 Avatar asked Oct 30 '22 01:10

bytecode77


1 Answers

I don't think there is any official specification about how long favicons should be cached (and why). You should rather ask browsers developers why they decided to cache them longer.

My guess is that since websites change favicons relatively rarely, there's no need to check very frequently if a favicon has been updated.

like image 113
Michał Perłakowski Avatar answered Nov 15 '22 08:11

Michał Perłakowski