Right now, I start using Interlis in QGIS (I never used Interlis before...). However, there seems to be a systematical encoding problem. When I select the transfer file and start the import, the following error message appears:

 UnicodeEncodeError: 'ascii' codec can't encode character u'\xe4'
 in position 40: ordinal not in range(128)

What do I need to change (step by step)?

  • Welcome to GIS:SE @NiklausZihlmann! Haven't used Interlis before either but what seems to be a common reason for your UnicodeEncodeError error is the username containing symbols or accents. Does your username contains these ASCII characters?
    – Joseph
    Commented Jul 3, 2017 at 9:01
  • @Joseph: no, it does not... the username is just 'nz'... Commented Jul 3, 2017 at 9:51
  • What is the default encoding of QGIS? is it ASCII? If yes, is there a way to change it to UTF-8? Might that be the problem? Commented Jul 3, 2017 at 9:54

1 Answer 1


An Interlis 1 transfer file (.itf) is always ISO-8859-1 encoded. An Interlis 2 transfer file (.xtf) is an XML file; the rules of XML apply (the encoding declaration in the xml prolog defines the encoding; default is UTF-8).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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