function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
NaradorNarador 

How do you set a custom favicon for Salesforce File public links?

We have in some of our Knowledge base articles public links to Salesforce Files. When a user opens one of these links, it opens a browser tab with the file and the favicon is the Salesforce cloud icon. Is there any way to apply a custom favicon to these public links? Salesforce support indicated that it would require applying a custom favicon to all Salesforce pages. Is this even possible?
Rahul Kumar 767Rahul Kumar 767
You can get a lot of results on Google about your query. Also, visit Kalia Yojana (https://pradhanmantri.info/kalia-yojana-list-odisha/
AbhishekAbhishek (Salesforce Developers) 
Hi Narador,

Yes, it possible.

Please follow the steps as mentioned in the below articles,

https://salesforce.stackexchange.com/questions/17184/how-do-you-customize-the-address-bar-icon-in-a-visualforce-page

https://developer.salesforce.com/forums/?id=906F0000000AhbMIAS

https://blogs.perficient.com/2017/08/01/favicons-your-salesforce-community-is-not-complete-without-one/


As this a new Implementation I don't have any other live examples to share with you.

Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future. It will help to keep this community clean.

Regards,
Salesforce Support.



 
NaradorNarador
Thanks, but those solutions are not what I am after. I am not using Visualforce pages, just exposing the files as public links, which essentially open the files in a tab like an internal Salesforce page. Is there a way to change the favicon of internal Salesforce pages? I would think this would allow external people who access those files to see the desired favicon. Here are some images of what I mean:

Here I create the link in Salesforce:
User-added image

We use it in the Article Content and display in our community, then the link opens a new tab with Salesforce:
User-added image
AbhishekAbhishek (Salesforce Developers) 
Hi Narador,

You can try using Hyperlinks 

https://help.salesforce.com/articleView?id=000320277&language=en_US&type=1&mode=1

But sorry as I mentioned earlier we don't have the official document for this scenario.

Regards,
Salesforce support.
Ankit Arora 30Ankit Arora 30
@Narador
Step 1: you need to create a static resource.
Set up > Static Resouce > new
Select the icon and make sure you are using .ico file and image size is 16X16 and set cache control to Public.
After saving, just confirm MIME Type is image/x-icon

Step2: Add the favicon to any sites or communities you use.
if you want to add it to sites, then go to set up > sites> select the site > Edit> Set Favourite Icon> look for the static resource you created in step 1.

Step 3: Add the code to VF pages above the <head> tag.

Copy this code to the VF page:
<link rel="shortcut icon" href="{!URLFOR($Resource.Favicon)}" type="image/x-icon" />    (Name of my favicon is "Favicon", it can be different for you)

Set up> VF page > Select VF Page > copy the above code.

-> Public links you are using must have some place to put the code.

Please let me know if this is helpful for you and mark it best answer if it resolves your issue.
Thank you

Regards,
Ankit