Favicon Generator

Drop one image and get the whole favicon set — six PNGs, a multi-size favicon.ico and the HTML to paste — made on your device, never uploaded.

  • Free
  • No account
  • Runs in your browser
  • Nothing uploaded
Favicon GeneratorNothing uploaded

Runs entirely in your browser — your input is never uploaded, logged, or stored.Privacy policy

What is Favicon Generator?

This favicon generator turns a single image into the complete set a website needs, and gives you the HTML to go with it, all inside your browser. From one PNG, JPG, WebP or SVG you get six PNG icons — 16, 32 and 48 px for the browser and Windows, 180 px as Apple's touch icon, and 192 and 512 px for a web app manifest — plus one multi-image favicon.ico that holds the 16, 32 and 48 px versions. Nothing is uploaded: the images are drawn and packed on your own device.

A favicon is the little picture that identifies a page: the tab, the bookmarks list, the history, the phone's home screen when a site is saved. Different places ask for different sizes, which is why a single 512 px PNG is not enough — the browser has to shrink it for a 16 px tab, and a picture built for a large size usually turns to mush at 16 px. Making each size deliberately gives a sharper result, and a proper favicon.ico means browsers that ask for /favicon.ico find a file that contains the small sizes they want.

Everything is square, because every icon slot is. If your image is not square, this tool centres it on a square and pads the extra space; it never crops, so nothing is cut off. The padding is transparent by default — leave "Fill the background" off — or tick it and choose a colour, which is the safer choice for a logo on a light or dark page that would otherwise show gaps. The image is measured at its own size and then each icon is drawn down from the full-resolution square with high-quality smoothing, so the small sizes are as clean as the browser can make them.

An SVG is handled a little differently and it is worth being precise: an SVG has no pixels, so your browser rasterises it — draws it into a bitmap — when the icons are made. The output of this tool is a set of PNGs either way; it does not give you a vector favicon. That is fine for a favicon set, but if you want a genuinely resolution-free icon you would link an .svg file yourself, which not every browser supports for the tab icon.

The HTML snippet is the standard, well-supported set. It links the 32 and 16 px PNGs with rel="icon" and the 180 px PNG with rel="apple-touch-icon". It deliberately does not link favicon.ico, because every browser requests /favicon.ico from the root of the site on its own — the snippet carries a comment saying so. It also does not include a rel="manifest" line, because this tool does not create a web app manifest: the 192 and 512 px PNGs are there for the manifest you write yourself, or the ones a platform asks for by name.

Limits, stated plainly. One image at a time, up to 20 MB; an SVG is drawn with its longer side at 512 px before scaling. If your source is smaller than 512 px, the 512 icon is enlarged and the tool says so, because it will look soft. Older versions of Safari ignore the sizes attribute on rel="icon" and may use the 180 px touch icon for the tab too. Browsers cache favicons hard, so a site can keep showing the old icon for hours after you replace it.

1. The file's real format is read from its bytes, not its name: PNG, JPG, WebP and SVG are accepted; anything else is named and refused. 2. The background option is checked — a hex colour, or none at all. 3. The package is planned as six PNGs (16, 32, 48, 180, 192, 512 px) and one favicon.ico holding 16 + 32 + 48 px. 4. The image is decoded; an SVG is first rewritten to render with its longer side at 512 px. 5. It is centred on a square of side max(width, height) with the offsets floored: dx = floor((size − width) / 2), dy = floor((size − height) / 2) — padded, never cropped, and transparent unless a colour was chosen. 6. Each PNG size is drawn down from that full-resolution square with high-quality smoothing (large reductions shrink in halving steps first) and encoded as PNG. 7. The 16, 32 and 48 px PNGs are packed, unchanged, into one favicon.ico — ICONDIR, then one ICONDIRENTRY per image, then each PNG, using the same encoder as the PNG to ICO tool. 8. The <link> snippet is written from the sizes the package actually contains.

What each file in the package is for
 Typical use
favicon-16x16.pngBrowser tab, bookmarks and history at standard density
favicon-32x32.pngBrowser tab and taskbar on high-density (Retina) screens
favicon-48x48.pngWindows Explorer and desktop shortcuts; also inside favicon.ico
apple-touch-icon.png (180)iPhone and iPad home-screen icon when a site is saved to the Home screen
favicon-192x192.pngAndroid home screen and PWA splash screen — referenced from a web app manifest
favicon-512x512.pngPWA install, splash screens and large icon slots — referenced from a web app manifest
favicon.icoA single file holding 16, 32 and 48 px, served from the site root for browsers that request /favicon.ico

Worked examples

  • A 512 × 512 square logo with no background → favicon-16x16.png, favicon-32x32.png and favicon-48x48.png, apple-touch-icon.png at 180 px, favicon-192x192.png and favicon-512x512.png, and one favicon.ico holding 16, 32 and 48 px.
  • A 1000 × 500 image → squarePad gives a 1000 × 1000 square; the picture sits at dx = 0, dy = 250, so the top and bottom 250 px bands are transparent (or the chosen colour). Nothing is cropped.
  • A 103 × 50 image → the square is 103 px and dy = 26 (53 ÷ 2 rounded down), so the image never spills past the bottom edge.
  • A 64 × 64 SVG → the browser draws it at 512 px first, then every icon is scaled down from that rasterised drawing, so the package is PNG bitmaps.
  • A file named logo.png that is really a WebP is detected from its bytes and works; a GIF is refused with a message naming it as a GIF.

How to use Favicon Generator

  1. Click "Choose a PNG, JPG, WebP or SVG image", drop a file on the box, or paste one with Ctrl+V (Cmd+V on a Mac).
  2. Leave "Fill the background" off for transparent padding, or tick it and pick a colour if your logo would otherwise sit on an unknown page colour.
  3. Click "Generate favicon package" and wait while each size is drawn.
  4. Download the files individually or all together as a ZIP, put them in your site's root folder, and paste the copied snippet into your page's <head>.

Common errors

  • "… is actually a GIF file, not PNG, JPG, WebP or SVG." — the file is a format this tool does not read, whatever its name. Convert it to PNG first.
  • "red is not a colour. Use a hex value such as #ffffff, or leave the background transparent." — the background must be a hex colour; use the colour picker or a value like #0f172a, or untick the option.
  • "… is 25.10 MB, over the 20.00 MB limit for this tool…" — resize or compress the image first; everything runs in your browser's memory.
  • "Your image is 240 × 180 px, so the 512 px icon was enlarged and may look soft…" — the source is smaller than the largest icon. Start from an image at least 512 px square for a crisp result.
  • "The output would be 20000 × 20000 pixels — more than a browser can safely draw…" — the decoded image is too large for a canvas; resize it down first.
  • The site still shows the old icon — browsers cache favicons aggressively. Hard-refresh, clear the site data, or rename or version the files.

FAQ

What files does a website need for its favicon?

A practical modern set is a small favicon.ico at the site root, 16 and 32 px PNGs linked with rel="icon", a 180 px apple-touch-icon.png, and 192 and 512 px PNGs for a web app manifest. This tool makes all of them from one image and writes the <link> tags for you.

How do I add the favicon to my site?

Put the downloaded files in your site's root folder so the paths like /favicon-32x32.png resolve, then paste the copied snippet just before </head>. favicon.ico needs no tag — browsers request /favicon.ico from the root automatically.

Is my image uploaded anywhere?

No. The image is decoded, drawn and packed into the icons inside your browser. You can confirm in your browser's developer tools (Network tab) that no request carries your file.

Why are there 192 and 512 px icons if the snippet doesn't use them?

They are the sizes a web app manifest asks for, used by Android when a site is installed to the home screen and for splash screens. This tool does not generate a manifest, so they are included in the download but not linked from the HTML snippet.

What happens to a non-square image?

It is centred on a square of its longer side and the extra space is padded — not cropped — so the whole picture survives. The padding is transparent by default, or the colour you choose if you tick "Fill the background".

Can I use an SVG as the source?

Yes. Because an SVG has no fixed pixels, your browser rasterises it when the icons are drawn, so the result is PNG bitmaps rather than a vector favicon. The tool warns you when this happens.

What sizes are inside favicon.ico?

16, 32 and 48 px, each stored as a PNG image — the small sizes browsers and Windows actually pick for tabs, taskbars and shortcuts. The larger 180, 192 and 512 px icons are separate PNG files.

Can I undo or regenerate the package?

Yes — the result is only held in this browser tab, so nothing is saved anywhere. Change the background option or the image and click Generate again; close the page and the files are gone.

G

Prefer AllUtil on Google

One click adds AllUtil to your Google preferences. You'll see our tools highlighted with a Preferred badge in Search and AI answers.

2× more likely to clickWorks in AI Overviews