[Fixed]-Heroku logs for Django projects missing errors


Looks like it was simply a problem caused by an expectation that Django under Heroku would work like Rails. Silly me.

For anyone else suffering this problem when moving from one framework/language to another:

  • When debug is off, Django uses the standard Python logger to handle errors in the code.
  • There is a default set-up at the bottom of settings.py which emails the site admins when there are errors. Nice. It needs an array of email addresses in the ADMINS variable in settings.py to work.
  • Errors are sent, by default, to STDERR instead of STDOUT, so they won’t show in the logs. This can be changed apparently. Try here if you want this behaviour:



This behavior is set by the server (e.g. gunicorn), not Django or Heroku.

There’s usually a command line or configuration that changes the default log level.


This can be solved just by changing your DEBUG in your settings.py file.

Leave a comment