Project Setup in Python

From the Django cheat sheet · Setup & Project Structure · verified Jul 2026

Project Setup

Create and configure a Django project

python
pip install django
django-admin startproject myproject
cd myproject
python manage.py startapp myapp
python manage.py runserver
💡 Always use virtual environments for Django projects
⚡ django-admin for project, manage.py for apps
📌 Keep sensitive settings in .env file
🟢 Run migrations after creating models

Continue with Django

Save the full cheat sheet or work through every related task.

Back to the full Django cheat sheet