What a favicon set includes
A favicon is the small icon browsers show in tabs, bookmarks and history. Phones use a larger version when someone adds a site to the home screen, and installable web apps take their icons from a web app manifest. One set of files covers all of these.
- favicon.ico: 16, 32 and 48 px in one file. Browsers also look for it at /favicon.ico when a page has no icon tags
- favicon-16x16.png and favicon-32x32.png: tab icons for standard and high-density screens
- apple-touch-icon.png (180 px): the icon Apple devices use when a site is added to the home screen
- icon-192.png and icon-512.png: listed in site.webmanifest for installable web apps and Android home screens
How the files are made
Letters are drawn in the font weight you choose and sized by the outline of the glyphs themselves, so they sit in the true middle of the icon. Images are scaled down in steps of one half, which keeps small icons cleaner than one large jump.
An ICO file is a small container: a header, one directory entry per image and then the images. Since Windows Vista the images inside may be PNG files, which every current browser reads, so favicon.ico here holds the same 16, 32 and 48 px PNGs you can download on their own.
Header 6 bytes reserved 0, type 1, image count 3
Directory entry 16 bytes per image: width, height, colors,
planes, bit depth, size, offset
Image data the 16, 32 and 48 px PNG files
Before the first PNG: 6 + 3 × 16 = 54 bytesFavicons for client sites
At 16 px there is room for very little, so a favicon works best as the simplest form of the brand. Studios often make it the last step of a launch, but it is worth agreeing on early, as clients see it every time they open the site.
- Use a single letter, a monogram or the logo mark without the wordmark
- Check it at 16 px on both a light and a dark tab, where thin lines and low contrast disappear first
- Give a transparent icon enough contrast against both tab colors, or use a background
- Browsers cache favicons for a long time: if a new one does not appear, test in a private window
- Keep the source artwork with the project, so the set can be made again after a rebrand