Key Ideas
1The Basic Favicon. A favicon is declared in the <head> using a <link> element with rel="icon". The browser shows it in the tab, bookmark bar, and other UI surfaces.
2Favicon Sizes. Different devices and contexts request different icon sizes. Here are the most important ones to include:
3SVG Favicons & Dark Mode. SVG favicons are the future — they scale perfectly to any resolution and can even adapt to dark mode using a @media (prefers-color-scheme) query inside the SVG itself.
4Web App Manifest. The site.webmanifest file (referenced by <link rel="manifest">) tells Android and PWA-capable browsers what icons to use when the user installs your site as a ho...