I got this code in this answer: Set Python27 Google AppEngine default encoding for entire app
#!/usr/bin/python
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
Do I have to do this just in main.py (file with request handlers) or to every single python file that I create?
Yes, like the from __future__ import
line the # coding
line only ever applies to the file it is placed in.
Python uses it when compiling the source file to bytecode, and you are free to use different encodings for different source files should you so wish.