Join my Laravel for REST API's course on Udemy 👀

Create a super user in Django

October 17, 2020  ‐ 1 min read

If you want to login to the Django admin site you need a user with is_staff or is_superuser set to true. You can create a user with the super user permissions by utilizing the createsuperuser command. This will prompt you for the required inputs for a user.

$ python manage.py createsuperuser
Username (leave blank to use 'koen'): admin
Email address: admin@koenwoortman.com
Password: *********
Password (again): *********
Superuser created successfully

Using this user account you should able to login to the Django admin site. It also acts like a general user account in a normal Django project. So you're also able to use it as a login on your self-made website.