About Concurrent Connections
The number of concurrent connections typically depends on a number of CPUs and Gunicorn workers.
The formula many use is:
number_of_workers = (2 × number_of_CPU_cores) + 1
For a typical small to medium Django site using Gunicorn:
- 2-4 workers is common for smaller sites.
- Each worker can handle around 2-12 concurrent connections.
- So approximately 4-48 concurrent connections total.
For medium to larger sites:
- 4-12 workers is typical.
- Which allows for roughly 8-144 concurrent connections.
If you use Whitenoise and serve static files via Gunicorn too, you should take into account that each static file will block the connections for other users.
Django/Python Consulting
If you have a specific Django challenge or integration you'd like to solve, I'd be happy to help. Book a free 30-minute call to discuss your project, see if we're a good fit, and explore the best approach for your needs. After the call, you'll receive a tailored cost estimate based on what we discuss.
Also by me
Django Messaging
For Django-based social platforms.
Django Paddle Subscriptions
For Django-based SaaS projects.
Django GDPR Cookie Consent
For Django websites that use cookies.