HTML / SEO - attach png icons / favicons with different sizes to your webpage

7 points
Created by:

In this short article, we would like to show how to attach proper icon sizes to your webpage that have a good impact on user experience and SEO.

Because of different devices and screen resolutions, it is good to use the following sizes: 
48x48, 72x72, 96x96, 144x144, 192x192, 256x256, 384x384, 512x512.

Simple steps:

  1. export your icons to ico, gif or png files:
    batch export from svg to png with Inkscape, you can find here,
  2. insert link elements with icon paths inside head element:
    it is good to use the proper sizes of icons to match different devices,
// ONLINE-RUNNER:browser;

<!doctype html>
  <link rel="icon" sizes="48x48" type="image/png" href="/gfx/icon-48x48.png" />
  <link rel="icon" sizes="72x72" type="image/png" href="/gfx/icon-72x72.png" />
  <link rel="icon" sizes="96x96" type="image/png" href="/gfx/icon-96x96.png" />
  <link rel="icon" sizes="144x144" type="image/png" href="/gfx/icon-144x144.png" />
  <link rel="icon" sizes="192x192" type="image/png" href="/gfx/icon-192x192.png" />
  <link rel="icon" sizes="256x256" type="image/png" href="/gfx/icon-256x256.png" />
  <link rel="icon" sizes="384x384" type="image/png" href="/gfx/icon-384x384.png" />
  <link rel="icon" sizes="512x512" type="image/png" href="/gfx/icon-512x512.png" />
  Web page content here...


Donate to Dirask
Our content is created by volunteers - like Wikipedia. If you think, the things we do are good, donate us. Thanks!
Join to our subscribers to be up to date with content, news and offers.


Native Advertising
Get your tech brand or product in front of software developers.
For more information Contact us
Dirask - we help you to
solve coding problems.
Ask question.

❤️💻 🙂