Preparing and deploying a Django application on eligible hosting

Django hosting requires a compatible Python environment and a production WSGI or ASGI deployment method. Confirm what your Nabtech plan supports before uploading the project. A Python selector does not automatically provide every system dependency, database or background worker your application may require.

01 Prepare a production configuration

Record supported Python and Django versions, dependency requirements, database engine and any task queue or cache service. Separate production secrets from source code. Plan file uploads, backups and a controlled database migration before switching a live application.

  1. Create the supported Python application environment in the panel, or agree the deployment method for an authorised server.
  2. Upload the application and dependency file. Install packages in that environment rather than changing the server's system Python.
  3. Configure the supported WSGI or ASGI entry point. Use the server integration's documented method; Django's development server is not the production hosting service.
  4. Set DEBUG=False, a private production SECRET_KEY and the appropriate ALLOWED_HOSTS. Configure the correct database and other environment values.
  5. Back up the database before running required migrations. Run manage.py check --deploy against the actual production settings and investigate relevant findings.
  6. Collect and serve static files through the approved web-server arrangement. Keep user-uploaded media separate from application code and prevent uploaded files from executing as scripts.
  7. Start or restart the app using the supported manager and test through HTTPS.

02 Verify the complete application

Check login, forms, database writes, static assets, uploads and outbound email. Test any background tasks separately. Confirm that error pages do not expose settings, source or tracebacks to visitors.

What causes common Django deployment failures?

A missing package, wrong environment, incorrect entry point or unavailable database can stop startup. A DisallowedHost error points to hostname configuration, while missing CSS often points to static-file handling. Review the relevant logs instead of turning production debugging on for everyone.

If the application requires a service unavailable in the selected plan, discuss a suitable VPS or managed deployment with us. Keep the previous working release and compatible database recovery plan until the new deployment is verified.

  • 0 Users Found This Useful
  • development
Was this answer helpful?

Related Articles

Deploying a Node.js application on an eligible Nabtech plan

Node.js applications need a supported runtime and a production process manager or hosting...

Hosting a React website: static builds and server-rendered applications

A React project can produce static files or require a running application server, depending on...

Checking Ruby application compatibility and deploying safely

Ruby applications, including Ruby on Rails, need a compatible runtime, dependencies and...

Resolving PHP memory exhaustion without hiding the cause

The PHP message Allowed memory size exhausted means a script tried to allocate more than its...