DEV Community

Cover image for How to Deploy a Django Site in 2022
Angus Allman
Angus Allman

Posted on • Originally published at


How to Deploy a Django Site in 2022

It’s a confusing place out there. You’ve built a great site with Django and the next step is getting it in front of people… but where to start?

A quick google of “Deploy Django Site” shows a whole host of responses and so today I’m going to try and break down the main ones and my personal favourite.


Firstly, there’s one of the biggest names in the deployment space: Heroku.
Heroku offers hosting solutions on their servers and is mostly managed through the terminal. They are tried and tested industry-level hosting perfect for professionals.

Heroku offers free plans as well as a very flexible pricing model allowing the user to pay for only what is used.

While this is an elegant solution for some, it’s daunting for people who haven’t got much exposure to the command line and tutorials online can be unclear, in my experience.

Digitalocean Marketplace

Up next is DigitalOcean. DigitalOcean offers a solution in their Marketplace which creates a new “Django Droplet” for you in their system, allowing you to upload your site to their containers, configure it and deploy.
This is a great solution for those who are comfortable with the command line and managing linux systems but, let’s be honest, it’s no mean feat to learn all you need to know about managing linux servers through the terminal.
This solution is also a one-time thing. It spins up the droplet for you and that’s it. Any further systems administration which is needed is done manually which can be time-consuming and confusing (I’ve been there).

The cost for the droplet is no more than a regular DigitalOcean droplet with all the same options, however, it’s worth noting that these "Django Droplets" can only be spun up in the San Francisco data center which may not be ideal for some users in other parts of the world.


PyHost offers a comprehensive system for deployment and system management.

The system allows users to create a server on DigitalOcean in any of their available data centers. It’s also possible to manually connect a VPS from another provider as long as it’s the correct OS and version (Debian 11). PyHost dynamically generates and runs scripts on your server, in addition to server setup like DigitalOcean provides, it also allows deploying of individual sites from Github, Bitbucket and Gitlab. If you don’t want to you’ll never have to access your server’s command line to get a simple site up and running. You are able to create new databases and manage users, get 1-click SSLs for your sites and configure environment variables through the system’s UI. Extensive documentation is available here and will guide you through the whole process.

You host the site yourself, maintaining all the power while never needing to bother with the terminal ( although that option is available, should you want it). Win/win!

PyHost boasts a free plan which allows deployment of one site with an auto-generated subdomain, as well as paid plans with more flexibility and power.


In summary, there are lots of options available to the modern Django developer in 2022. Deployment is a confusing and often intimidating process that isn’t helped by the amount of choice on offer.

If you are comfortable with the terminal and want something that does a few things well, then Heroku and DigitalOcean are your best bets. However, if you want to spend as little time worrying about systems administration as possible then PyHost is the one you want. I truly believe that PyHost takes the weight off the developer and allows them to focus on what matters to them, the code. So get out there and build amazing apps and don’t sweat about hosting anymore because PyHost’s got your back

Top comments (1)

maxlarsenjr profile image
Max Larsen


Top Heroku Alternatives (For Free!)

Recently Heroku shut down free Heroku Dynos, free Heroku Postgres, and free Heroku Data for Redis on November 28th, 2022. So Meshv Patel put together some free alternatives in this classic DEV post.