Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

How do I import and use custom fonts?

Hello, UE4 community! I've been using UE4 and so far I really enjoy it, but I can't seem for the love of me to get fonts working... I do the right click -> materials and textures -> fonts in the content browser, and it does not matter what font I import, every time I apply that font to any text renders, it turns it into a bunch of incomprehensible symbols. I've tried messing around with different fonts, sizes, text, even colors to no avail... I'm sure I'm doing something wrong, I just don't know what it is. If you'd be so kind, you could tell me how you'd go ahead and use your font on some text in-game step-by-step, just in case. Thank you for your time.

Product Version: Not Selected
more ▼

asked Apr 27 '14 at 03:39 PM in Using UE4

avatar image

331 46 64 74

avatar image clord Apr 27 '14 at 06:14 PM

I'm seeing this too, the UV offsets are all wrong for the resulting font file, so you get random bits of adjacent characters. I've tried several different fonts to no avail.

avatar image jfaztk Apr 27 '14 at 06:21 PM

Thanks for replying. I'm guessing we're not the only ones experiencing this, so it'll probably be fixed eventually.

avatar image Megumi May 04 '14 at 09:32 PM

Did you create a new Text Material which references the corresponding font?

avatar image jfaztk May 04 '14 at 09:53 PM

Yes, it still didn't work.

avatar image Ozotron Oct 05 '14 at 04:10 AM

Not working for me. I'm using 4.5. (preview)

I tried the below answer 3 or 4 times now (double checked all textures, fonts and materials)

I tried Arial at 20 and 100, and my custom other font. Neither are working. Is there any other options that I need to set for import other than the Distance Field check box?

avatar image STUDIO PONCHO Nov 18 '14 at 07:59 AM

Not working for me in 4.5 on OSX. I tried Tahoma. With some fonts I can just about see the right characters but they are rendered at crazy heights up and down. Others I just get random glyphs. Did anybody get this to work on OSX? The standard font works fine but any imported fonts render corrupted. I followed all steps above several times.

avatar image STUDIO PONCHO Nov 19 '14 at 04:11 AM

Ok looks like my problem is related to the import of the font. The font import Preview window should show your font rendering the sentence on a black background, and the sentence to render beneath it on a white background. It looks like I need to fiddle around with the Distance Scale Factor and Distance Field Scan Radius to get this to not be a bunch of random glyphs. I am confused but I will persevere. Good luck folks... :-)

avatar image Tim Hobson ♦♦ STAFF Nov 19 '14 at 10:58 PM


I was inspired to start throwing together a Wiki tutorial for this after trying to research and finding not a lot of helpful documentation in the area of fonts. This is a known area that needs some work so for the moment I am currently in the process of getting the rough draft done. I'll get that up soon, but in the meantime I can help you out here with a few tips for getting some better results for your Font for TextRender Actor.

For your imported Font Texture that was rendered you'll want to condense everything down to one page. Have you adjust the the Width/height and then reimported the asset? I have not tested this on a OSX, but if there is any problem I have access to a Mac that I can make sure everythign is working.


avatar image STUDIO PONCHO Nov 20 '14 at 03:42 AM

Great - thanks Tim! Do you mean Texture Page Width/Height? I just about got my font to work in the game world by messing around with the settings (which I don't understand at all) but it still looks pretty poor. Imported another font tonight (American Typewriter) to use in the HUD and that one looks ok but it doesn't render any spaces so the words are all jammed together. I'm afraid I don't know if this is user error or an OSX issue on 4.5.1. It does seem to me that out of the box importing fonts is very hit and miss on OSX, so probably worth a look.

avatar image Tim Hobson ♦♦ STAFF Nov 20 '14 at 03:40 PM

My experience with importing fonts is rather limited. I saw the hiccup happening here and figured I'd start looking into it and then found that there isn't a lot of information to work off of. Most of my experience thus far is from looking at what's in the engine and a lot of trial and error. I've really only imported fonts as a font texture and for use with TextRender Actors. I'm not sure if there would be a difference with UMG and the HUD. I'll keep at it and see if I can work in a test on OSX soon. I'll update with anything I find that may be helpful. :)

avatar image HartLabs May 18 '17 at 02:40 AM

It is important that your font is only one 1 page. Had a ton of problems with gibberish showing before realizing this.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

This is a long story... but the steps outlined below work for me at any rate.

First of all, a font imported the ordinary way will in fact work fine, but not for a TextRenderActor specifically. However, if you use it in a DrawText node in the HUD blueprint, it will perform as expected. Just wanted to point that out.

Anyway - to make a font for TextRenderActors, do this:

  1. Import your font as per usual, and rename it to something like "{your_font_name}DistanceField" to make it easier to tell it from an "ordinary" font later on.

  2. Open the newly imported font by double-clicking it in the Content Browser.

  3. In the Details panel of the Font Editor, search for "Distance" and you'll find a checkbox labeled "Use Distance Field Alpha". Check that box now.

  4. In the "Asset" menu of the Font Editor, click "Reimport {your_font_name}DistanceField"

  5. Wait for it to process. This can take quite a while. It seems like a good idea to make the initial import at a moderate point size, like 20 - 24 or something, to keep the number of font pages down. Otherwise the reimport turns into a good opportunity to take a lunchbreak. So, a simple font with a minimal glyph set is a good thing in this context.

  6. Save and close the Font Editor when the reimport is complete.

  7. Now place a standard TextRenderActor into your scene by dragging it from the Modes panel.

  8. In the Details panel, you'll find that the TextRenderActor uses a material called DefaultTextMaterialOpaque. This is part of the Engine contents, not visible by default in the CB. Click the magnifying glass icon to browse to the asset in the content browser.

  9. The engine contents should automatically load in the CB, and the material in question is highlighted.

  10. Drag it into your Game folder and select the 'Copy' option when prompted.

  11. Rename your copy to 'MyTextMaterial' or something equally imaginative... Then open it in the Material Editor.

  12. In the Material Editor, select the Font (Font Param) node and change the name of the font in the Details panel to the name of your font.

  13. Apply, save and close the ME.

  14. Back in the level editor, select the TextRenderActor again and change its material in the Details panel to your new 'MyTextMaterial'

  15. In the Text section (still details panel) set the correct font in the Font drop-down. This seems a bit reduntant, but it appears necessary from what I've seen here.

  16. Enter your text and marvel at: a) your new font in the scene, and b) the fact that you've just read and followed all these instructions (and that someone posted them).

It is quite possible that I've inadvertently left some step out, but this should probably get you going in the right direction.

more ▼

answered May 04 '14 at 10:55 PM

avatar image

2.1k 64 54 120

avatar image jfaztk May 04 '14 at 11:09 PM

Thanks! I'd hate to wonder how you found out how to do all that >.<

avatar image Xenome May 05 '14 at 08:21 PM

You're welcome. Please mark the topic as Resolved if my solution worked for you.

avatar image jfaztk May 06 '14 at 10:00 PM

Sorry... But it won't work. It still gives me weird hieroglyphs, except this time around they look different. I've tried with multiple fonts to no avail.

avatar image Xenome May 06 '14 at 10:25 PM

Maybe you're going too big? Ideally, the standard set of alphanumerical glyphs should fit on one texture page. Try a perfectly normal font like Tahoma at size 20 for instance:

alt text

avatar image jfaztk May 06 '14 at 10:57 PM

Sorry for the trouble. I fixed it. I accidentally forgot to switch the font inside the material... Thanks xD

avatar image Xenome May 06 '14 at 11:17 PM

No trouble at all. Glad you got it working. Fonts are important stuff.

avatar image Tom Shannon May 16 '14 at 01:31 AM

Aw jeez. thanks for showing me how to do line breaks :D

avatar image jfaztk May 05 '14 at 08:24 PM

Where do I mark it as resolved?

avatar image SVAD May 15 '14 at 02:16 AM

There is a checkbox up near the answer, under the votes, visible only to you.

avatar image Alvaro Vazquez Jul 06 '14 at 12:11 AM

Thanks! it works

avatar image wmbuRn Aug 24 '14 at 10:41 PM

Not working for me. Still getting weird symbols. Engine 4.4.0 and 4.2.1. Any other way ?

avatar image pchan126 Sep 12 '14 at 11:54 PM

The Tappy Bird game uses custom fonts for TextRenderComponents, with its own blueprint for making text materials. I'm not 100% pleased with the results applied to the font I'm using, but its pretty straightforward to copy.

avatar image cailei Dec 27 '14 at 04:55 PM

I'm trying to render Chinese text with TextRenderActor/TextRenderComponent but have no luck, then I found this post and find myself was trying with 'dynamically' cached font while this post is suggesting a 'offline' cached one (signed distance field font).

So this basically means TextRenderComponent cannot render 'dynamically' cached fonts?

I have a UMG HUD which can render 'dynamically' cached font fine, so I'm thinking that should be possible with TextRenderComponent.

Chinese characters are way too many to bake into offline cache textures (which is absolutely a non-fun task), so 'dynamic' cache is my only rescue, please give me some pointer!

avatar image Alexander Paschall ♦♦ EPIC Jan 09 '15 at 07:36 PM

This is quite a bit different than the original post. Could you make a new thread for your question? That will help us track the answers better.

avatar image jwatte Apr 21 '15 at 03:16 PM

Plus all the points!

avatar image mxnko May 11 '15 at 12:25 AM

Cannot find Distance field in engine version 4.7.6

avatar image mxnko May 11 '15 at 01:24 AM

Got it. You have to switch the Font Cache Type from Runtime to Offline. Then all those options appear.

avatar image Candy_swift Aug 21 '15 at 06:17 PM

Thanks a lot!)

avatar image LittleRainCloud Nov 12 '15 at 07:35 AM

I love you Xenome, May the blessings of ripe virgins rain upon you.

avatar image Marjane Apr 16 '16 at 06:26 PM

Thank you Xenome! You really helped my font problem :)

avatar image Botfly08 Sep 07 '17 at 09:53 AM

Cheers Mate, worked a charm !!!

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Thank you Xenome!For all of people in this problem,after setting what Xenome said,you should change font on TexturerenderActor's setting to your cuttom font,it defalut will make render wrong.

more ▼

answered Oct 11 '16 at 05:44 AM

avatar image

1 1 1 2

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question