Intermediate CSS

What are Favicons?

Favicon means favorite icon, which is displayed on the title bar. You can also create your own favicon on sites like:

https://www.favicon.cc/

and then download your icon.

To add a favicon to your website, either save your favicon image to the root directory of your web server, or create a folder in the root directory called images, and save your favicon image in this folder.

And then add a link in the index.html file and write an icon in the stylesheet and address your icon under href. For Example:

HTML:

<!DOCTYPE html>
<html>
<head>
  <title>My Page Title</title>
  <link rel="icon" href="/images/favicon.ico">
</head>
<body>

<h1>This is a Heading</h1>
<p>This is a paragraph.</p>

</body>
</html>

Copy this clipboard and paste it into your code editor and also add a favicon on the images folder.

Comments

Popular Posts