I recently changed from texmaker to texstudio and i'm facing this ugly problem that doesn't leave to split my text into several files. Here's my main file:


\usepackage[spanish,es-noquoting, es-tabla, es-lcroman]{babel} 

 Extensión producto

I'm getting the error:

Package inputenc Error: Unicode char \u8:ónpr not set up for use with LaTeX Extensión pr

Does anybody know why this happens?

  • Are you sure your file was utf8 encoded?
    – Bernard
    Commented Oct 4, 2017 at 20:04
  • the form of the error you show means that you have an old latex, and that your file is not in UTF-8 encoding but you have specified \usepackage[utf8]{inputenc} Commented Oct 4, 2017 at 20:09
  • I can reproduce the exact error if I encode the input as Latin-1, but process it as you do with the utf8 option to inputenc.
    – egreg
    Commented Oct 4, 2017 at 20:10
  • @egreg and use a two year old inputenc, presumably. Commented Oct 4, 2017 at 20:12
  • @DavidCarlisle Yes, but the bulk of the error message was the same
    – egreg
    Commented Oct 4, 2017 at 20:17

1 Answer 1


If you save your test file in UTF-8 encoding then it will run without error. If you save it in latin1 (iso-8859-1) you get the error

! Package inputenc Error: Unicode char ónpr (U+153)
(inputenc)                not set up for use with LaTeX.

See the inputenc package documentation for explanation.
Type  H <return>  for immediate help.

l.8 Extensión pr

with current latex, or the slightly less readable but equivalent error message that you showed, on older versions of LaTeX.

So you can re-encode your file by saving it in utf-8 or declare to latex that it is in latin1 by changing the line to

  • sorry but in fact the file is saved with utf8 (i checked it on the texstudio settings) and still i have the same problem. in fact with the bigger text that originated the error i get a warning "data encoding is utf8" Commented Oct 4, 2017 at 20:40
  • @Rodrigo no your main file may be utf8 but the file that has that text is not, the bytes shown in the error message match the latin1 encoding of that text. Commented Oct 4, 2017 at 21:02

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .