Favicon tagFavicon tag

Posted February 7th, 2009 in HTML and CSS

A favicon is the little icon you see in your browser address bar and in your favorites/bookmark list. By default web browsers look for the file favicon.ico in your website's root directory but it's possible to specify a different location for the favicon. I'm always having to look this up myself if I need to specify a different location so am posting how to do this here as my reference point.

In the <head> section of your HTML document, add the following tag:

<link rel="shortcut icon" href="/path/to/your/favicon.ico" />

and substitute the /path/to/your/favicon.ico with the actual name of your favicon file.

Related posts:

Comments

blog comments powered by Disqus