Using Custom Fonts In Service Portal - PUBLIC Pages

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-02-2017 09:18 AM
I'm trying to use custom fonts (font icons) in Service Portal on a public page, but with no success. There is a great post with multiple options on how to add custom fonts (Using Custom Fonts In Service Portal) and Options #3 works perfect for logged in users. However, it doesn't work for a public role.
I tried read ACLs for sys_attachment and sp_css tables with public role, but with no success.
Any ideas on how to make custom fonts available for a public page?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-23-2017 12:56 PM
Hello Andrew,
You might want to try looking into PRB575228 plus it has a workaround attached.
LINK:https://hi.service-now.com/nav_to.do?uri=/kb_view.do%3Fsys_kb_id%3Dd653d05c87c6bc40b43083bdff434d48
Thanks.
PS - Please mark Helpful, Like, or Correct Answer if above details worked out for you.
Paryul Jain
Technical Support Engineer UX
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-12-2018 01:15 PM
You can use the attachment method but instead of using the fonts as
url('sys_attachment.do?sys_id=FONT_ATTACHMENT_SYS_ID')
Write it as follows:
url('FONT_ATTACHMENT_SYS_ID.iix')
We have used it successfully with both public and private sites.
PS - Please mark Helpful, Like, or Correct Answer if applicable.
Thanks,
Ritesh Dalal
Service Portal Pro
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-04-2018 06:21 AM
This solution worked for me as well. Thanks for the tip!
before:
@font-face {
font-family: 'ComicSans';
src: url('/sys_attachment.do?sys_id=1d401529dbb9570001947d8bbf961974') format('woff2'),
url('/sys_attachment.do?sys_id=d9401529dbb9570001947d8bbf961970') format('woff');
}
after:
@font-face {
font-family: 'ComicSans';
src: url('1d401529dbb9570001947d8bbf961974.iix') format('woff2'),
url('d9401529dbb9570001947d8bbf961970.iix') format('woff');
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-10-2021 07:40 AM
Hello
3 years later, I'm facing this issue. I tried your solution, and I got a 403 forbidden. Is there something else to do to make it work?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-10-2021 02:26 PM
As Brad, Nathan, and Andrew have previously posted... this is the best method.
Embedding fonts using Base64
The best way to include custom typefaces in your portals is to simply Base64 encode the .TTF fonts and create a simple stylesheet.
- Navigate to https://www.fontsquirrel.com/tools/webfont-generator
- Click "Upload Fonts" button to upload the custom .TFF font files
- Click "Expert..." radio button
- In the CSS section towards the bottom of the page check the "Base64 Encode" checkbox
- Click "Download Your Kit" button.
- Copy the contents of the "stylesheet.css" file you just downloaded
- Open a new CSS record in ServiceNow and paste the contents
- Relate the new CSS record to your Service Portal Theme
- Write CSS that will designate your custom font to be used by certain HTML elements
Disclaimer. You MUST make sure that the fonts you are encoding are legally eligible for web embedding. If you are a Partner/Consultant ask the client to ensure that the fonts can be used for web embedding and get it in writing, an email. If you are an employee do the same. Fonts are artisan level works of art and the foundries deserve to get paid!
Convert your fonts from .TTF to Base64
Open the downloaded "stylesheet.css" file and copy the contents
Paste into a fresh CSS record
Relate the new CSS record to your Service Portal Theme
Examples of CSS you can write to designate the custom fonts to be used by certain elements
body {
font-family: 'volte_roundedregular',Arial,sans-serif;
}
h1, h2, h3, h4, h5, h6 {
font-family: 'volte_roundedbold',Arial,sans-serif;
}