[SalesForce] Custom Font not working In Custom HTML email template

I have created static resource and included ttf file for gotham font, when I used below code in visualforce page it is rendering as expected. but when same I included in custom html email template it does not render in gmail,outlook

@font-face{
font-family: 'Gotham';
src: url(/resource/GothamFont);
}

Can you please help me on this?

Best Answer

This is not related to Salesforce, but to web-safe fonts.

Majority of Email clients have no support for custom fonts, even today. While there are few that partially support them, Gmail unfortunately isn't.

As alternative you can look into utilizing Google Sans or Roboto in Gmail, these are supported as of late 2018.

You'll also need to beware of any custom font EULA, as typically web fonts are not licensed to be used in Emails legally.

Read more - Litmus Guide to Web Fonts in Email (2019)

And this - Web Fonts in Email (2019)

Related Topic