Django community: RSS
This page, updated regularly, aggregates Community blog posts from the Django community.
-
Trailing URL Slashes in Django
Among Django's many built-in features is [APPEND_SLASH](https://docs.djangoproject.com/en/4.0/ref/settings/#append-slash), which by default is set to `True` and automatically appends a slash `/` to URLs that would otherwise [404](https://en.wikipedia.org/wiki/HTTP_404). **Note**: The Chrome web … -
What is Django (Python)?
[Django](https://djangoproject.com) is an open-source web framework written in the [Python](https://www.python.org) programming language. Named after the jazz guitarist [Django Reinhardt](https://en.wikipedia.org/wiki/Django_Reinhardt), it is used by some of the largest websites in the … -
How to Get Hired as a Django Developer
Hiring developers is a famously non-linear problem. Once you have a job at a notable company, it seems recruiters constantly beat down your door. But how do you get started? … -
NameError: name 'os' is not defined
If you've started a new Django 3.1+ project and are using older tutorials or guides, it's likely to come across the following error on your command line: ``` NameError: name … -
Django Polls Tutorial API
The [polls tutorial](https://docs.djangoproject.com/en/dev/intro/tutorial01/) is the official guide to Django. As a fun exercise, I wanted to show how little code it takes to transform it into a robust API using … -
Django Testing Tutorial
Testing is an important but often neglected part of any Django project. In this tutorial we'll review testing best practices and example code that can be applied to any Django … -
What's New in Django 3.1
Django 3.1 will be released in early August 2020 and comes a number of major new features and many minor improvements including asynchronous views and middleware support, asynchronous tests, JSONField … -
The 10 Most-Used Django Packages
Inspired by a past article on [The 22 Most-Used Python Packages in the World](https://medium.com/better-programming/the-22-most-used-python-packages-in-the-world-7020a904b2e), I teamed up with [Jeff Triplett](https://jefftriplett.com/about/) to investigate the top 10 Django packages based on [PyPI](https://pypi.org/) … -
Django Best Practices: Function-Based Views vs Class-Based Views
Django's use of both function-based views (FBVs) and class-based views (CBVs) causes a lot of confusion for newcomers. Why have multiple ways to do the same thing? And which one … -
Django Best Practices: Referencing the User Model
Django has a powerful, built-in [user authentication system](https://docs.djangoproject.com/en/4.0/topics/auth/default/) that makes it quick and easy to add [login, logout, and signup functionality](https://learndjango.com/tutorials/django-login-and-logout-tutorial) to a website. But how should a Django developer … -
Command Line for Beginners
The _command line_ is a powerful text-only interface for computers. If you have ever seen a show where hackers are furiously typing into a black window, that's the command line. … -
Django Email/Contact Form Tutorial
Let's build a simple contact form that sends email for a Django 4.1 website. We can take advantage of Django's built-in [email support](https://docs.djangoproject.com/en/dev/topics/email/) to make this relatively painless and then … -
Django Hello, World 5 Different Ways
Django is a "batteries-included" framework that comes with built-in scaffolding provided by the `startproject` command and the general concepts of apps. But, actually, Django provides incredible flexibility if desired around … -
Django Hosting & Deployment Options
[Django](https://www.djangoproject.com/) websites can be deployed on any number of hosting providers. The first choice is deciding whether to use a Platform-as-a-service (PaaS) option or a virtual private server (VPS). A … -
How to Learn Django (2023)
__Note__: I gave a version of this tutorial at DjangoCon US 2022. You can see the video here: -
Official Django REST Framework Tutorial - A Beginners Guide
This is a beginner-friendly guide to the official Django Rest Framework [tutorial](http://www.django-rest-framework.org/tutorial/1-serialization/) that works for both Windows and macOS. If you have struggled to complete the official tutorial on your … -
Psycopg3 Binary and Django 4.2 Installation Quick Tip
One of [Django 4.2's major features](https://docs.djangoproject.com/en/4.2/releases/4.2/#psycopg-3-support) is support for [Psycopg 3](https://www.psycopg.org/psycopg3/), the new implementation of the popular PostgreSQL adapter for Python. It is a replacement for Psycopg 2 that adds … -
Top 10 Django Third-Party Packages
Django is a "batteries-included" web framework, but it really shines with its robust ecosystem of third-party packages that add additional functionality to the framework. There are almost 4,000 available at … -
Deploy Django + PostgreSQL on Fly.io
In this guide we will develop a Django Todo application locally and then deploy it on [Fly.io](https://fly.io) with a [Postgres production database](https://fly.io/docs/reference/postgres/). There are a number of steps needed to … -
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, …