← All blog posts

Common mistakes when calculating favicon

WhiteUI · A plain-English guide to the Favicon Generator

Most favicon problems are not design problems — they are calculation problems, and they all come from the same few mistakes. A favicon that looks fine on your own screen can turn into a blur on a phone, a blank square in a bookmark bar, or a squashed logo in the tab. This post lists the five slips with the numbers behind each one, so you can spot them before they go live. Check your own files as you read, using the Favicon Generator to re-export anything that needs fixing.

Two 16 pixel icons: one made from a 512 pixel source is crisp, one made by stretching a 16 pixel source 32 times is a blur
Same size, very different result: 16 px shrunk from 512 px is crisp, while 512 px stretched from 16 px is a blur.

1. Making only one size

The commonest mistake is exporting a single 16-pixel file and expecting it to work everywhere. It will not. A phone home screen needs 180 or 192 pixels, and when it only finds a 16-pixel file it stretches it more than 11 times per side, which turns a crisp letter into a smear. The fix is to export the full set from one 512-pixel drawing: 16, 32, 48, 180 and 192. Five files sounds like a lot, but they are all made from the same drawing in one pass, and each device then picks the size it wants.

2. Stretching a small file up

The second mistake is the reverse: starting from a 16-pixel file and stretching it to 512. The scale factor is 32 per side, so the browser has to invent 1,023 pixels for every real one, and the result is a blur, not a bigger icon. This happens when someone saves the 16-pixel tab icon and tries to use it as the master file. The fix is to go back to the original drawing at 512 pixels — or redraw the letter at 512 — and export down from there. Shrinking keeps 1 pixel in 1,024 and throws away detail you cannot see; stretching invents detail that was never there.

3. Squeezing a wide logo into a square

Favicons are square, and a wide logo does not fit one. Take a banner logo that is 800 pixels wide and 200 tall — a ratio of 4 to 1. Squeezed into a 32 × 32 square without changing its shape, it becomes 32 pixels wide and 8 tall, filling only 25% of the height and leaving the rest empty. Stretched to fill the square, it is distorted beyond recognition. Either way the result is unreadable. The fix is not to resize the logo but to redesign for the square: take one letter from the name, or one simple shape from the logo, and draw that at 512 × 512. A favicon is a new design at a new size, not a shrunken logo.

4. Using the wrong format

PNG is the right format for a favicon in almost every case: it supports transparency, it compresses flat colour well, and every modern browser reads it. The mistakes are using JPEG, which has no transparency and smudges flat colour, and using an old single-size ICO file when a set of PNGs is needed. The ICO format still has one use: a single ICO file can hold 16, 32 and 48 pixels together — 14,336 bytes of picture data plus 54 bytes of header and directory entries, about 14 KB before compression — so it is a handy fallback for old desktop browsers. But it is a fallback, not the main set: the PNGs do the real work.

5. Forgetting the phone sizes

The last mistake is forgetting that phones exist. A site that only has 16, 32 and 48 pixels looks fine on a desktop, because those are the sizes desktops use. But when someone saves the site to a phone home screen, the phone finds no 180 or 192 file and falls back to a screenshot of the page or a blank icon — and a blank icon on a home screen looks broken. The Apple file is 180 × 180, or 32,400 pixels, and the Android file is 192 × 192, or 36,864 pixels. Both are one export each from the same 512 master, and both need a link tag in the page head. Add them once and every phone shows the right icon.

Frequently asked questions

What is the most common favicon mistake?

Making only one size. A single 16-pixel file turns into a blur when a phone stretches it to 180 or 192 pixels. Export 16, 32, 48, 180 and 192 from one 512-pixel drawing.

Can I stretch a 16-pixel favicon up to 512?

No. The scale factor is 32 per side, so the browser must invent 1,023 pixels for every real one, and the letter turns into a blur. Always redraw or re-export from 512.

Why does my wide logo look bad as a favicon?

Favicons are square. An 800 × 200 logo squeezed into 32 × 32 becomes 32 × 8 pixels, filling only 25% of the height. Use one letter or one simple shape instead.

Is JPEG okay for a favicon?

No. JPEG has no transparency and smudges flat colour. Use PNG for the sizes, and keep an ICO file only as a fallback for old desktop browsers.

More guides on the Favicon Generator

Try it yourself

Try the Favicon Generator — free, in your browser.

Open the Favicon Generator