How to add emojis as subtitle?

I would like to display emoji and text when the player coming close to something. But I failed to insert emoji as “text”. How should I fix this problem (with Hub)?

Sadly it seems Slate (UE4 UI system) does not support surrogating in UTF-16 properly (but it display last resort properly for some reason) and can only display 16-bit characters (from 0x0000 to 0xFFFF) while emoji is between 0x1F900 to 0x1F9FF making it technically UTF-32 (beyond 16-bit) characters and in order to access from UTF-16 which encoding that UE4 is using it needs to support surrogate character sequences and Slate seems to not display font with those characters properly, while it seem to detect use of Plane 1 (0x10000-0x1FFFF) and display Plane 1 LastResort character (the squere icon informing there missing font for that character, increase font size UMG editor). There possibility that issue is in font importing rether then displaying

You can try to investigate yourself, in order to even start thinking to display emoji at all you need to get a font that has emoji, you can experiment with Nato Emoji font:

Importing Fonts in Unreal Engine | Unreal Engine 5.1 Documentation - this is info on font importing

This should be enough… but as mentioned above there some issues displaying characters above 0xFFFF range

If current issues you might try using private use range charaters (0xE000-0xF8FF) in early days when emoji was only used in Japan they used that range but you need font that has emoji on that range and you need to convert your subtitles to use them, UE4 should not have problem displaying those.

Here you have some useful links:
Character Encoding in Unreal Engine | Unreal Engine 5.1 Documentation - overall information about character encoding in UE4

Universal Character Set characters - Wikipedia - below you have info about private use range

Full Emoji List, v15.0 - list of emoji characters in unicode

Also note some mobile OSes consider characters in 16-bit range (0x0000-0xFFFF) range as emoji and display colorful image, most notibly gender symbols, card symbols, arrows, stars, zodiac symbols etc. but those are old characters used in unicode way before emoji became a thing and they should normally be displayed as they sit below 0xFFFF if you have proper font imported to UE4

I submitted a bug with result of my investigation as it seem support of surrogated characters is half way done, so they either need to move that forward or remove sign of support of those that i noticed. I will see what will happen, im unicode maniac myself it would be nice to see support for that ;] But considering it is not that important i would not expect for this to be fixed quick.

I got this to responce of my bug raport… and it seems they not expected to support surrogates, so only solution would be either what i meantied use of private use zone or try implment something in C++ as with slate you can control widget rendering on quite low level, but as said below it is more preformance heavy task:

We store our FString characters in 16
bits (Essentially UCS-2), so anything
outside of the Basic Multilingual
Plane will be cut off. You can find
more information on our Character
Encoding page:
Character Encoding in Unreal Engine | Unreal Engine 5.3 Documentation

Unicode does provide a block of
Surrogate codepoints that can be
paired up, so you could detect that a
character is out of bounds, but by
then you’ve lost the second half.
Upping our character type to 32 bits
would double the memory footprint of
text across the board, which
definitely isn’t desirable. UTF-8/16
supports codepoints of varying byte
length, but the performance hit for
decoding it would be untenable. We can
definitely render the Symbols
(http://unicode.org/charts/PDF/U2600.pdf)
block, as long as you use a font that
includes those characters.