Why is my favicon not displaying on my site?

Why is my favicon not displaying on my site?

Chris_Whalley
New Member
6 0 0

Our favicon used to show but it hasn't been showing for a while now. I followed some advice on other discussions and pasted the below in the href of the favicon code in theme.liquid:

 

<link rel="shortcut icon" href="" type="image/png" />

 

I also made sure my favicon image I uploaded to the site was 96x96 and png.

 

Favicon is currently still not showing on our site: https://www.twentytwoshop.com/ 

 

Any suggestions?

Replies 5 (5)

Ihor-Sh
Shopify Partner
79 11 17

Hi @Chris_Whalley. Wrong value in href attribute.
Upload your icon to assets folder. In theme code add such part (instead of current): 

 

<link rel="shortcut icon" href="{{ 'your-file-name.png' | asset_url }}" type="image/png">

 

If I managed to help you then, don't forget to Like it and Mark it as Solution!

Shopify troubleshootibility 😉
If you're satisfied with reply - don't forget to like it.
If you more than satisfied - mark it as solution 😉
You can find me here.
Chris_Whalley
New Member
6 0 0

Thanks. How do I upload to assets folder?

Ihor-Sh
Shopify Partner
79 11 17

2024-02-06_13-03.png

Shopify troubleshootibility 😉
If you're satisfied with reply - don't forget to like it.
If you more than satisfied - mark it as solution 😉
You can find me here.
Chris_Whalley
New Member
6 0 0

Thanks just done that. This is what the coding currently looks like - is this correct?Capture.PNG

 

 

hfound
Excursionist
23 0 3

Did you get this fixed?  I just fixed mine with the below code:

 

{%- if settings.favicon != blank -%}
<link rel="icon" type="image/png" href="{{ settings.favicon | image_url: width: 32, height: 32 }}">
{%- endif -%}

 

Just go into your theme.liquid code, search "favicon", delete old code and replace with the above.  Worked like a charm for me!