Change this to just "wordlist.html". This is not the place for handling paths. That is done in the app.pt file which includes and names the templates according to pyramid's static route generation.