Found this useful information here: # -*- coding: utf-8 -*- def mylen(word): u""" <----- SEE 'u' HERE >>> mylen(u"áéíóú") 5 """ return len(word) print mylen(u"áéíóú")