Cannot Set Favicon


I'm hosting a free website through Hostinger, and I can't seem to set the favicon at all no matter what I try. I put it in my .htaccess:

RewriteBase /
ErrorDocument 404 /404.html
RewriteRule ^favicon.ico /favicon.ico [L]

I my favicon.ico in my root folder /public_html. And I added it to my page like this:

<link rel="icon" type="image/x-icon" href="favicon.ico">

What else can I do? My website is still displaying the default favicon. How do I fix this?

By : bjskistad


You have set up an infinite redirect. Going from favicon.ico to favicon.ico to favicon.ico to ...

Remove the rewrite rule and change the href attribute to href="/favicon.ico".

This video can help you solving your question :)
By: admin