I'm inputting a file into LaTeX (in verbatim mode) that contains a unicode smiley character, code 128512.

I thought declaring


would do the trick, but:

Package inputenc Error: 128512 too large for Unicode.
  • marvosym.sty tikzsymbols.sty and arev.sty also having good smilies
    – MadyYuvi
    Oct 16, 2019 at 9:08

1 Answer 1


\DeclareUnicodeCharacter takes the codepoint in hexadecimal notation:

Hello 😀

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.