Django community: Community blog posts RSS
This page, updated regularly, aggregates Community blog posts from the Django community.
-
Django Hello, World + Fly.io Deployment
In this tutorial, we will build a "Hello, World" website with Django and then deploy it to [Fly.io](https://fly.io/). If you want to learn Django properly, I provide step-by-step instructions and … -
Django RSS Feed Tutorial
Django comes with a built-in [syndication feed](https://docs.djangoproject.com/en/dev/ref/contrib/syndication/) for dynamically generating [RSS (Really Simple Syndication)](https://en.wikipedia.org/wiki/RSS) or [Atom](https://en.wikipedia.org/wiki/Atom_(web_standard)) feeds. These feeds contain recently updated content on a website, and users can subscribe … -
How to Install Django
This tutorial covers how to properly install the latest version of [Django (4.2)](https://www.djangoproject.com/) and [Python (3.11)](https://www.python.org). As the [official docs note](https://docs.djangoproject.com/en/dev/topics/install/), if you are already familiar with the command line, … -
Django File (and Image) Uploads Tutorial
This tutorial shows how to implement file and then image uploading with Django. We'll build a basic Instagram clone. ## Setup Whether you're on a Windows or Mac laptop the … -
Flask vs Django (2023)
[Flask](https://palletsprojects.com/p/flask/) and [Django](https://www.djangoproject.com) are the two most popular [Python-based](https://www.python.org) web frameworks. Both are mature, open-source, and have many happy users. A natural question therefore is: which one to use? In … -
Frequently Asked Questions about Django
## What is Django? Django is a Python web framework that takes care of the difficult and common parts of web development--authentication, database connection, CRUD (Create, Read, Update, Delete) operations, … -
Django ORM and QuerySets Tutorial
The Django [Object-Relational Mapper (ORM)](https://docs.djangoproject.com/en/dev/topics/db/) is one of the most powerful aspects of the web framework, an abstraction layer that allows developers to write object-oriented Python code which is translated … -
Django Sitemap Tutorial
Django has a built-in [sitemap framework](https://docs.djangoproject.com/en/dev/ref/contrib/sitemaps/) that allows developers to generate sitemaps for a project dynamically. A sitemap is an XML file that informs search engines of your website's pages, … -
Django Log In with Email not Username
Django was first released in 2005 and since then a lot has changed in web development, notably the predominant pattern at the time of using username/email/password has been simplified to … -
pre-commit with Django
[pre-commit](https://pre-commit.com/) is a widely-used code quality framework. It allows a developer to add [hooks](https://git-scm.com/book/en/v2/Customizing-Git-Git-Hooks) for various code quality tools that check your code for any errors or issues _before_ committing … -
Add robots.txt to a Django website
A "bot" is a general term for an automated program that does things like crawl the web. Google and other search engines rely on bots to periodically crawl the internet. … -
Django Static Files and Templates
Static files like CSS, JavaScript, and fonts are a core piece of any modern web application. They are also typically confusing for Django newcomers since Django provides tremendous flexibility around … -
Django Dependency Management with pip-compile and pip-tools
Even a basic Django project has multiple dependencies. After installing Django itself, various third-party packages--and their dependencies!--must be installed and managed. How do you track version numbers in a reproducible … -
Django Login and Logout Tutorial
In this tutorial, we'll learn how to configure login/logout functionality with Django's built-in [user authentication system](https://docs.djangoproject.com/en/4.2/topics/auth/). This post is the first in a three-part series that also covers [signup](https://learndjango.com/tutorials/django-signup-tutorial) and … -
Django Signup Tutorial
title: "Django Signup Tutorial" description: Add a signup/user registration page in Django 4.2. Previously, we [added login and logout pages](https://learndjango.com/tutorials/django-login-and-logout-tutorial) to our Django app. In this tutorial, we'll create a … -
Django Password Reset Tutorial
title: Django Password Reset Tutorial description: Implement user authentication with a password reset for Django 4.2. This tutorial demonstrates adding a password reset sequence to a Django application. It builds … -
Django, Docker, and PostgreSQL Tutorial
This tutorial will create a new Django project using Docker and PostgreSQL. Django ships with built-in SQLite support, but even for local development, you are better off using a "real" … -
Django Best Practices: Custom User Model
Django ships with a built-in [User model](https://docs.djangoproject.com/en/4.0/ref/contrib/auth/#django.contrib.auth.models.User) for authentication and if you'd like a basic tutorial on how to implement login, logout, signup and so on see the [Django Login … -
Django Slug Tutorial
In this tutorial, we will add slugs to a Django website. As noted in the [official docs for slugfield](https://docs.djangoproject.com/en/4.2/ref/models/fields/#slugfield): "slug" is a newspaper term, a short label for something containing … -
Django Best Practices: Template Structure
There are two main ways to organize your template structure in Django: the default app-level way and a custom project-level approach. ## Option 1: App Level By default, the Django … -
Django Favicon Tutorial
This tutorial explains how to add a favicon (shortcut icon) to a Django website. A favicon is a small icon that appears at the top of a tab in a … -
Django Best Practices: Projects vs. Apps
Within a single Django "project" can exist multiple "apps," which are used to separate discrete functionality. For example, a Django website might need an application for static pages like an … -
Django-allauth Tutorial
Django comes with a robust built-in authentication system for users but it does not provide support for third-party (social) authentication via services like Github, Gmail, or Facebook. Fortunately, the excellent … -
Seniority and self-management: you don't have to do this alone
At a certain level of seniority – typically the Staff level for ICs, and the Director level for managers – you’ll be expected to fully own huge areas of responsibility without detailed guidance. The mistake that many people make when they’re new to this level of autonomy is believing they have to do it all themselves. It is absolutely true that, once you reach this level of seniority, you are responsible for a very broad scope of responsibilities, skills, and tasks, but you don’t have to do this alone. At this level of seniority, you have to recognize your weaknesses, figure out what kind of support you need, and take steps to get yourself that support. -
Django News - Django 5.0 Testathon - Sep 29th 2023
News Django Developers Survey 2023 The Django Developers Survey is wrapping up for the year. Please do take a few minutes to fill it out. It is the ONLY way for the Django community to get an unbiased sense of actual usage, which helps guide new features and updates. jetbrains.com Python Developers Survey Numbers for 2022! The results of the sixth official annual Python Developers Survey are now out. blogspot.com Updates to Django As you probably already know, the Django 5.0 alpha is released!!! This means we've now entered a testing period for 5.0 and new features accepted into Django will be part of 5.1. I want to give a massive congratulations to everyone who has been involved in 5.0 - it is a really fantastic release! Last week we had 22 pull requests merged into Django by 11 different contributors - including 4 first time contributors! Congratulations to Toan Vuong, Fabian Braun, Arian and Clément Escolano for having their first commits merged into Django - welcome on board! The final feature of 5.0 was adding support for prefetching GenericForeignKeys via a new class GenericPrefetch. Yet another fantastic feature! You can see an example of how this should be used …