Django Settings Accessing settings

Help us to keep this website almost Ad Free! It takes only 10 seconds of your time:
> Step 1: Go view our video on YouTube: EF Core Bulk Extensions
> Step 2: And Like the video. BONUS: You can also share it!

Example

Once you've got all your settings, you'll want to use them in your code. To do so, add the following import to your file:

from django.conf import settings

You may then access your settings as attributes of the settings module, for example:

if not settings.DEBUG:
    email_user(user, message)


Got any Django Question?