To add a favicon, make a square icon at 32, 180, 192 and 512 pixels, upload the files to your site, and add link tags to the head of every page: link rel="icon" for the tab icon, link rel="apple-touch-icon" for iPhone home screens, and link rel="manifest" for a web app manifest that lists the larger icons. Keep a favicon.ico at the site root as a fallback for tools that look there by default. On a website builder you usually skip the code and upload one image in the settings instead.
Before you start
What adding a favicon actually involves
A browser finds a favicon in one of two ways. It reads the link tags in the head of the page, which say where each icon lives and what size it is. If there are none, many browsers fall back to asking for a file called favicon.ico at the root of the site. Adding a favicon properly means serving both.
There are two routes. If you control the HTML, you make the files and write the tags yourself. If you use a website builder, you upload one image in a settings page and the builder generates the files and tags. The steps below cover the first route in full, and the last section covers the second.
Either way, start with a good square image. The guide to favicon sizes explains why 512 by 512 pixels is the right starting point, and why the design has to be legible at 16 pixels.
The method
Add a favicon by hand in six steps
This is the full method for a site where you edit the HTML. File names are conventions, not rules, as long as the tags point at the right files.
Make the image files.
From one square source, export favicon-32.png at 32 by 32 pixels, apple-touch-icon.png at 180 by 180, and icon-192.png and icon-512.png for the manifest. Optionally add an icon.svg for browsers that support vector icons.
Make a favicon.ico.
Convert the small PNG into an ICO file, ideally holding 16, 32 and 48 pixel versions. Place it at the root of the site so it answers at yoursite.com/favicon.ico.
Upload the files.
Put the PNG and SVG files in a folder your site serves publicly, such as the site root or an icons folder. Open each URL in a browser to confirm it loads and is not blocked or redirected to a login page.
Write a web app manifest.
Create a small JSON file, often named site.webmanifest or manifest.webmanifest, with your site name, a theme colour and an icons list naming the 192 and 512 pixel files with their sizes and type.
Add the link tags to the head.
In the head of every page, add link rel="icon" type="image/png" sizes="32x32" pointing at the PNG, link rel="icon" type="image/svg+xml" for the SVG if you have one, link rel="apple-touch-icon" sizes="180x180", and link rel="manifest" pointing at the manifest.
Publish and check.
Deploy the change, open the site in a fresh tab and look at the tab icon. Then check the files load on a phone. If an old icon appears, the guide to a favicon that is not showing explains the usual causes.
The tags
What each link tag tells the browser
Each tag has one job. Knowing which is which makes it easy to debug later.
rel="icon"
The tab icon
The main favicon tag. You can list several, each with its own type and sizes, and the browser picks the best match for the screen it is drawing on.
sizes
The size hint
Written as width x height, such as 32x32, or any for an SVG. It lets a browser choose without downloading every file first.
type
The format hint
Such as image/png or image/svg+xml. A browser that cannot use a format skips that tag and moves on to the next one.
apple-touch-icon
iPhone and iPad
The icon iOS uses for a home screen bookmark. Without it, iOS may use a screenshot of the page instead, which rarely looks good.
rel="manifest"
Android and installed apps
Points at the manifest file, which lists the 192 and 512 pixel icons Android uses for home screen shortcuts and installed apps.
/favicon.ico
The silent fallback
Not a tag at all. Browsers and tools that find no link tags often request this path directly, so serving it avoids a missing icon.
Common mistakes
Where favicon setups usually go wrong
The most common mistake is adding the tags to the home page only. A visitor who arrives on an inner page from a search result then sees the fallback, or nothing. Put the tags in the shared template or layout so every page carries them.
The second is pointing a tag at a path that does not resolve. A relative path such as icons/favicon.png works on the home page but breaks on a page two folders deep. Use paths that start with a slash, or full URLs.
The third is caching. Browsers hold on to favicons for a long time, so a replaced file can look like a failed change. Giving the new file a new name, or adding a version query such as ?v=2 to the tag, tells browsers to fetch it again.
Two routes
Adding a favicon by hand versus in a website builder
Both routes end in the same files and tags. The difference is who makes and maintains them.
| Capability | Folio | By hand in HTML |
|---|---|---|
| Files | Generated from one uploaded image | Exported and converted yourself, size by size |
| Head tags | Added to every page automatically | Written into your template and kept correct |
| Manifest | Generated with the right icons and colours | Written and updated as a JSON file |
| Changing the icon later | Choose a new image and save | Re-export every size and bust the cache |
Hand coding gives total control. A builder removes the steps that are easy to get wrong.
On Folio
Adding a favicon to a Folio site
On Folio the favicon is your site icon, and there is nothing to code. If you have a profile photo, your site already uses it. To change it, open Settings, choose Brand and theme, and in Site icon choose Profile photo, Monogram or Custom image. For a custom image, upload a PNG, JPEG or WebP file or pick one from your media library, check the Preview, and choose Save site icon.
Folio then publishes the files and the tags on every page: an SVG icon, a 32 pixel PNG, a 48 pixel shortcut icon, a 180 pixel Apple touch icon, a 144 pixel Windows tile and a manifest with 192, 512 and maskable 512 pixel icons. Requests for favicon.ico are sent to the 48 pixel copy, and every icon link carries a version that changes with your icon, so visitors get the new one on their next visit.
Frequently asked questions
What is the HTML code for a favicon?
In the page head, add link rel="icon" type="image/png" sizes="32x32" href="/favicon-32.png", link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png", and link rel="manifest" href="/site.webmanifest". Add the same lines to every page.
Where do I put the favicon file?
Anywhere your site serves publicly, as long as the link tags point at it. Also keep a favicon.ico at the root of the site, because some browsers and tools look for that exact path when no tag is present.
Do I still need favicon.ico?
It is worth keeping. Modern browsers follow your link tags, but some tools, feed readers and older browsers still request /favicon.ico directly, and serving it costs nothing.
Why did my favicon not change after I uploaded a new one?
Usually the browser cache. Browsers keep favicons for a long time, so rename the file or add a version query to the tag, then reload in a new tab or a private window to check.
Can I add a favicon without editing code?
Yes, on most website builders. You upload one square image in the site settings and the builder makes the sizes and adds the tags. On Folio that setting is Site icon, in Settings under Brand and theme.