Skip to content

Instantly share code, notes, and snippets.

@matallo
Created March 11, 2015 10:48
Show Gist options
  • Save matallo/46cd1cfa474e09fa3f80 to your computer and use it in GitHub Desktop.
Save matallo/46cd1cfa474e09fa3f80 to your computer and use it in GitHub Desktop.

For the favicon, it's best for cross-browser compatibility not to use any HTML. Just name the file favicon.ico and place it in the root of your domain. 1

An .ico file is a container for multiple .bmp or .png icons of different sizes.

generate PNGs:

  • non-retina: 16×16px
  • retina: 32×32px

if you use Sketch you can use the this template:
https://www.dropbox.com/s/l1re5ofo2lzyxzq/favicon.sketch?dl=0

convert PNGs to .ico:

install imagemagick 2

$ convert favicon-16.png favicon-32.png favicon.ico
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment