Getting Started
Goal for this part
By the end of this snapshot you will have a Django project that starts with manage.py runserver and shows the default rocket page. That sounds small on purpose: Django’s layout is easier to learn when you see a living project before apps, templates, and models enter the picture.
Campus Press starts as a standard django-admin startproject tree. You create a virtual environment, install Django, and confirm the development server answers in the browser. Later folders keep this same project shape while adding a blog app around it.
What you should already know
You do not need prior Django experience. You should be comfortable opening a terminal, running python3, and editing a .py file. Knowing what a function is and how import works will help.
A virtual environment isolates this project’s packages from the rest of your system. If that idea is new, skim the linked Python lesson on virtual environments before you install anything.
- You can run commands in a terminal
- You know how to save and run a Python file
- Optional: you have used
piporvenvonce before
What Django is doing for you
A browser sends an HTTP request to a URL. Django’s URL configuration matches that path to a view, the view builds a response (often via a template), and Django returns HTML or other content. Settings, apps, and middleware sit around that path so common web needs stay organized.
Unlike a single-file microframework, Django separates the project (site-wide settings and root URLs) from apps (features like a blog). Understanding that split early makes every later part less mysterious.
Walkthrough: project layout you will see
manage.py is the command-line entry point for migrations, the dev server, and the shell. The inner project package (often named campus_press or similar) holds settings.py, urls.py, and wsgi.py/asgi.py.
For this part you do not need to edit those files yet. Running the server proves your install works and that you are in the correct folder.
campus_press/
manage.py
campus_press/
__init__.py
settings.py
urls.py
wsgi.py
asgi.py
How to run it and what you should see
Clone the teaching repo, move into the 01-Getting-Started folder, create a virtual environment, activate it, and install dependencies from the parent requirements.txt. Shared packages live at the repo root so every snapshot can reuse the same list.
Start the app with python manage.py runserver. In the terminal you should see Django’s development server and a line pointing at http://127.0.0.1:8000/. Open that URL. You should see Django’s default success page (the rocket), which means the project boots correctly.
git clone https://github.com/michaeldunga1/fcc-django-blog.git
cd fcc-django-blog/01-Getting-Started
python3 -m venv .venv
source .venv/bin/activate
pip install -r ../requirements.txt
python manage.py runserver
Common mistakes and troubleshooting
If the browser cannot connect, confirm the terminal still shows the server running and that you used port 8000. If imports fail, make sure the virtual environment is activated and you installed with pip install -r ../requirements.txt from inside the snapshot folder.
Running from the wrong directory is a frequent issue: manage.py must be in your current folder. Stay inside 01-Getting-Started for this part.
- Activate the venv before
pip installorrunserver - Use the parent requirements file:
../requirements.txt - Stop the server with Ctrl+C, then start it again after major changes
Try this
Open settings.py and find INSTALLED_APPS and DEBUG. You do not need to change them yet—just notice where Django keeps site-wide configuration.
Then stop the server and start it on another port with python manage.py runserver 8001. Confirm you understand how the URL in the browser must match the port you chose.
- One project tree with
manage.pyat the root of the snapshot - Shared dependencies live in the repo root
requirements.txt - Confirm http://127.0.0.1:8000/ shows the default page before moving on
Next: Apps and Routes
Comments
One comment per signed-in account. Comments are saved with this page’s URL.