- Make sure to include
dj-database-url==0.5.0in yourrequirements.txtfile. - Add the following line at the bottom of
settings.pyfile:import os import dj_database_url if 'DATABASE_URL' in os.environ: DATABASES = { 'default': dj_database_url.parse(os.environ['DATABASE_URL'], conn_max_age=600) }