Skip to content

What is a favicon? Sizes, HTML code and free favicon icons

5 December 2026 ยท 4 min read

A favicon is the small icon you see on a browser tab. It sits next to the name of the page. It also shows up in bookmarks, in your history and in search results. This guide shows you how to make one and add it to your site.

Why a favicon matters

A favicon helps people find your tab when they have lots of tabs open. It also makes your site look finished. A site with no favicon shows a plain grey globe or a blank page.

What size is a favicon?

A browser tab shows the favicon at 16 by 16 pixels. On a sharp screen it uses 32 by 32 pixels. Phones and tablets use bigger sizes for home screen icons.

Where it shows Size in pixels
Browser tab 16 x 16 or 32 x 32
Bookmarks and history 32 x 32
iPhone and iPad home screen 180 x 180
Android home screen 192 x 192
Android start-up screen 512 x 512

You do not have to make every size by hand. If you give the browser one big picture, it will shrink it for you.

Step 1: pick a simple icon

A favicon is tiny. So the icon has to be simple. Thin lines and small details will not show at 16 pixels.

These styles work well:

Pick an icon that fits what your site is about. A house suits a property site. A shopping cart suits a shop. A book suits a blog about reading. You can browse all the icons to find yours.

Every icon on Smash Icons is free to use as a favicon. You do not need an account, and you do not have to give credit.

Step 2: download it

Open the page for your icon. Download two files:

  • the SVG, for new browsers
  • the PNG, for older browsers and for phones

Our PNG files are 512 pixels wide with a clear background. That is big enough for every size in the table above.

Step 3: put the files on your site

Rename the files to favicon.svg and favicon.png. Upload them to the main folder of your site. This is the folder that holds your home page.

Step 4: add the HTML code

Put these lines in the <head> part of every page:

<link rel="icon" href="/favicon.svg" type="image/svg+xml">
<link rel="icon" href="/favicon.png" type="image/png">
<link rel="apple-touch-icon" href="/favicon.png">

The first line is for browsers that can show an SVG favicon. The second line is the backup for the ones that cannot. The third line is for the home screen on an iPhone or iPad.

Do you use a site builder such as WordPress, Wix, Squarespace or Shopify? Then you do not need the code. Look for "site icon" or "favicon" in the settings and upload the PNG there.

What about favicon.ico?

ICO is the old file type for favicons. Browsers look for a file called favicon.ico in the main folder of a site when the page has no favicon code. All current browsers can use a PNG, so you do not need an ICO file. If you want one for very old browsers, a free ICO converter can make it from the PNG.

My new favicon does not show

Browsers keep the old favicon for a long time. Try these steps:

  1. Open the favicon file itself in your browser. For example, go to yoursite.com/favicon.png. If you see the icon, the file is in the right place.
  2. Reload your page with Ctrl + F5. On a Mac, use Cmd + Shift + R.
  3. Open the page in a private window.
  4. Wait a day. Search engines can take a few weeks to show the new one.

Tips for a good favicon

  • Keep it simple. One clear shape is best.
  • Use strong colours. Pale icons fade on a light tab.
  • Check it on dark tabs. A dark icon with a clear background can vanish on a dark browser. A colour badge behind the icon fixes this. App and circle icons already have one.
  • Match your brand. Use the same colour as your logo or your buttons.

More from the blog