Skip to content

Help Centre › Websites, files and databases

How do I set up a Python app in cPanel?

If your cPanel shows Setup Python App under Software, create the application there, upload your code, install your packages with Run Pip Install and restart it. Python apps are not listed as a web hosting plan feature, so if you don’t see that icon, ask us before you build; a KVM VPS runs any Python stack.

Setup Python App runs web apps built with Flask, Django or another WSGI framework, each in its own virtual environment.

  1. Log in to cPanel and look under Software for Setup Python App. If it isn’t there, stop and ask us on WhatsApp what your plan supports.
  2. Click Create Application. Choose the Python version, an Application root folder outside public_html (for example pyapp) and the Application URL. Leave the startup file as passenger_wsgi.py and the entry point as application, then click Create.
  3. Upload your code into the application root with File Manager or FTP, including requirements.txt.
  4. Edit passenger_wsgi.py so it loads your app (see below).
  5. Back in Setup Python App, edit the application, add requirements.txt under configuration files and click Run Pip Install.
  6. Click Restart and open the application URL.

What goes in passenger_wsgi.py

FrameworkLine to use
Flask, with app = Flask(__name__) in app.pyfrom app import app as application
Django, project called mysitefrom mysite.wsgi import application

For Django, also add your domain to ALLOWED_HOSTS, set DEBUG = False, and use a MySQL database created in cPanel (see How do I create a MySQL database?).

Tip: The app loads your code once and keeps it in memory. After every upload or settings change, click Restart, or you will still see the old version.

Web hosting suits small web apps and APIs. Background workers, task queues, websockets and anything needing system packages belong on a KVM VPS, with full root access, from $15 a month.

Still stuck? Open a support ticket with the application URL and what you see, or message us on WhatsApp.

Updated 6 November 2026. Something here out of date? Tell us.

Ask us on WhatsApp