How do I customize the Favicon for my Ghost Blog (Casper theme)? It seems to use the “Publication icon” for the favicon, but I’m looking to overwrite that.
I can’t find anywhere in the Casper source code where a favicon is specified, it seems to be declared outside the theme.
Like you said, you can replace it in the Ghost Admin area, simply deleting the current icon and uploading your own icon.
Another option is using the code injection section (header).
Assuming you have your icon in the root folder, you can add the following line:
The easiest way for me was to grab the image I wanted to use, make it 60 x 60 then add .ico to it on the computer. After that just upload it under publication icon.
Thanks, but to clarify, I’m not looking to change the “publication icon”, since that is used for more than just the favicon. I want to keep the publication icon the same, but override the favicon only. Does that make sense?
I’d like to do the same as what you’re indicating here, but with the Dawn theme instead. Did you find a way to override the publication icon being used as the favicon?
Will come back here to update in case I find something Thanks for posting the original question.
@brightthemes I am having a similar issue - I need to use a .svg to update the favicon colours based on the theme.
I followed your advice and added the following to the code injection
Thanks @Cathy_Sarisky
Yes I indeed meant using the asset helper!
The bigger issue however is not loading the favicon svg, I can do that via the publication icon.
What I want to do is use an SVG created as a file in my ghost assets so that I can change the colour based on whether the user has dark mode or light mode enabled on their browser.
I believe that you can edit the SVG and add a style into it to detect the mode selected.
but it does not load the SVG file instead preferencing the file specified under the publication icon field - when I remove the publication icon, no favicon is loaded