How can I add a .ttf file as a custom font?

Whenever I upload my font file as an asset, it counts it as an image. How can I upload a custom font and use it in CSS?

I think it’s just a normal .ttf file in the assets page because mine looks like this
I think it’s just a placeholder image they put over it

1 Like

HI @Jhondoe2122 - if you want that asset in your app folder, open the terminal and run wget [asset url here] and it will download the file. Then run refresh so it will show up in the editor sidebar.

I found that you can just upload the asset and use font-face. Thanks anyway.

Edit: For anyone who went to this forum page because they wanna do this too, I’ll show you.
In your styling sheet, implement this base I designed:

@font-face {
        font-family: "Font Family Name";
        src: url("");

Let’s use Futura PT Extrabold as our example.

Basically, upload your .otf or .ttf file as an asset, get the link, go to your stylesheet, make a font face for said font, with the link and name, and then use it as the font-family on your element. Just in case, i would add fallback fonts.

1 Like

Yeah, that placeholder was what was confusing me initially.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.