Set up a Python app in cPanel with Setup Python App. Pick an interpreter, point Passenger at your WSGI callable, and install packages with Run Pip Install.
Updated: August 9, 2026
By Matic BončinaFounder
✓Proofread & verified
Setup Python App registers a Python web application under your cPanel account. It builds a private virtualenv for the app, then hands the process to Phusion Passenger, which imports your WSGI callable and feeds it requests. You never start a server yourself.The tool is CloudLinux’s Python Selector. Each app picks its own interpreter from the alt-python packages installed on the server, so two apps in one account can run different versions.
Python is included on BONFIRE, BLAZE and INFERMO. SPARK and FLAME don’t come with it, so those plans need an upgrade before Setup Python App appears in cPanel.
Twelve interpreters are installed and available to pick from:3.13.12, 3.12.13, 3.11.15, 3.10.20, 3.9.23, 3.8.20, 3.7.17, 3.6.15, 3.5.9, 3.4.10, 3.3.7, 2.7.18Take the newest one your dependencies support. Everything below 3.9 is past upstream end of life and is there for old applications that can’t move yet.
The version dropdown starts on 2.7.18. The Selector has no default version configured, so the form opens on the first entry in the list, which is Python 2. Create an app without touching that dropdown and you get a Python 2.7 virtualenv. Change it before you click CREATE.
From cPanel home, scroll to Software and click Setup Python App.
cPanel home → Software → Setup Python App
2
Click CREATE APPLICATION
On an account with no apps yet, the page shows WEB APPLICATIONS and NO APPLICATIONS FOUND. Click CREATE APPLICATION to open the form.
3
Fill in the form
Five fields, plus an environment variable panel:
Python version: change it off 2.7.18 unless you really want Python 2.
Application root: the directory holding your code, relative to your home directory, such as myapp. This is the only mandatory field.
Application URL: pick a domain, then add a path if you want one. Leave the path box empty to serve the app at the domain root.
Application startup file: the file Passenger imports, usually passenger_wsgi.py. The field starts empty and there is no default, so type it in.
Application Entry point: the name of the WSGI callable inside that file. cPanel describes it as “Setup wsgi callable object for your application”. The usual answer is application.
Environment variables: click ADD VARIABLE for anything your app reads from the environment.
Setup Python App → CREATE APPLICATION
4
Click CREATE
The Selector creates the app root, builds the virtualenv, and switches to the management view for the new app. You’ll see the activation command for its virtualenv at the top of that page.
Creating an app writes three things into your application root: a public directory, a tmp directory holding restart.txt, and a placeholder passenger_wsgi.py. Replace that placeholder with your own file.The virtualenv lands outside the app root, at ~/virtualenv/<app-root>/<major.minor>/. An app on 3.13.12 gets ~/virtualenv/myapp/3.13/.
Opening an existing app shows the same fields you filled in, now with controls across the top and extra panels below.
Control
What it does
STOP APP
Stops the running application.
RESTART
Restarts it. Passenger also restarts on its own when the timestamp on tmp/restart.txt changes.
SAVE
Applies changes you made to the fields on this page.
DESTROY
Unregisters the app and deletes its virtualenv. Your application directory and files stay.
OPEN
Opens the application URL in a new tab.
Run Pip Install
Installs from a requirements file you list under Configuration files.
Run Script
Runs a Python script in the app’s environment, such as manage.py migrate.
ADD VARIABLE
Adds an environment variable.
There is no separate Edit button. The management page is the form, so change a field and click SAVE.
DESTROY leaves your files behind. It removes the Passenger registration and deletes ~/virtualenv/<app-root>/, but the application directory itself, including your code, tmp/, and any log files, stays exactly where it was. Delete it in File Manager if you want it gone.
Passenger doesn’t run your file as a script. It imports the file named in Application startup file and looks for the callable named in Application Entry point. With the usual pairing of passenger_wsgi.py and application, that means a top-level name application has to exist.For Flask:
Passenger speaks WSGI. FastAPI, Starlette and Django Channels are ASGI, so they need a bridge in front of them. a2wsgi provides one:
passenger_wsgi.py
from a2wsgi import ASGIMiddlewarefrom main import app as asgi_appapplication = ASGIMiddleware(asgi_app)
That covers ordinary request and response traffic. WebSockets and long-lived streaming don’t survive the translation, because WSGI has no model for them. If you need those, you need a process listening on its own port, which this tool doesn’t provide. Open a ticket and we’ll talk through the options.
The app booted on Python 2.7 and I didn't ask for it
The version dropdown opens on 2.7.18 and stays there unless you change it, so an app created in a hurry ends up on Python 2. Check the Python version field on the management page, set the one you wanted, and click SAVE. Reinstall your packages afterwards with Run Pip Install, since the environment your app uses is tied to the interpreter.
Passenger can't find an application callable
The name in Application Entry point has to exist as a top-level name in the file named in Application startup file. If your Flask object is called app, either rename it or alias it: application = app. Check both fields on the management page before you go digging through your code.
ImportError on a package you just installed
The package went into the system Python rather than the app’s virtualenv. Use Run Pip Install from the management page, or activate the environment first in SSH with the command that page prints.
Django static files return 404
Passenger serves the WSGI application and nothing else, so /static/ isn’t handled for you. Run collectstatic and serve the output as ordinary files. The Deploy Django guide walks through the layout.
A pip install fails partway through
Memory is rarely the culprit. Plans that include Python start at 6 GB of RAM on BONFIRE and reach 12 GB on INFERMO, which is comfortably enough for prebuilt wheels like pandas or numpy. The more common trigger is a package with no wheel for the interpreter you chose, which drops pip into a source build. Check which version the app is on first, then send us the pip output if it still won’t install.
A cold boot times out
Passenger’s documented default gives an application 90 seconds to start before it gives up and logs an error. Slow migrations or heavy imports at module level can run past that. Move that work out of startup, or open a ticket and we’ll look at the boot log with you.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Noxity Knowledgebase","colors":{"primary":"#B83553","light":"#FF3A6D","dark":"#B83553"},"logo":{"light":"https://mintcdn.com/noxity/AKndteo9-AwoOj4e/logo/dark.png?fit=max\u0026auto=format\u0026n=AKndteo9-AwoOj4e\u0026q=85\u0026s=76f2b0618a4cdbd4376d51ddab0477f0","dark":"https://mintcdn.com/noxity/AKndteo9-AwoOj4e/logo/light.png?fit=max\u0026auto=format\u0026n=AKndteo9-AwoOj4e\u0026q=85\u0026s=c835ef08ea2abe8acf6a38c869c730bf"},"favicon":"https://mintcdn.com/noxity/AKndteo9-AwoOj4e/logo/favicon.png?fit=max\u0026auto=format\u0026n=AKndteo9-AwoOj4e\u0026q=85\u0026s=a02d7b87c0b53b9ac4bf89e3d17447b6","appearance":{"default":"dark","strict":true},"background":{"color":{"light":"#EFEBE3","dark":"#131A28"}},"navbar":{"links":[{"href":"https://noxity.io/blog","label":"Blog"},{"href":"https://status.noxity.io","label":"Status"},{"href":"https://noxity.io/support","label":"Support"}],"primary":{"type":"button","label":"Members Area","href":"https://members.noxity.io"}},"footer":{"socials":{"website":"https://noxity.io","discord":"https://community.noxity.io","twitter":"https://twitter.com/noxityio","youtube":"https://www.youtube.com/@noxityio","github":"https://github.com/noxitylabs","instagram":"https://www.instagram.com/noxityio","linkedin":"https://www.linkedin.com/company/noxity"}},"fonts":{"heading":{"family":"Manrope","weight":700},"body":{"family":"Manrope","weight":400}},"icons":{"library":"fontawesome"},"styling":{"eyebrows":"breadcrumbs","codeblocks":{},"latex":false},"errors":{"404":{"redirect":false,"title":"Lost in the data centre","description":"You found a URL we don't serve. The page either moved when we ported the legacy knowledgebase, or a link somewhere got mangled in transit. Try the **search at the top**, the suggested matches below, or jump straight to one of these:\n\n\u003ca href=\"/welcome\" className=\"kb-pill\">Home\u003c/a> \u003ca href=\"/web-hosting/overview\" className=\"kb-pill\">Web Hosting\u003c/a> \u003ca href=\"/domains/overview\" className=\"kb-pill\">Domains\u003c/a> \u003ca href=\"/home/essentials/support\" className=\"kb-pill\">Open a ticket\u003c/a>"}},"contextual":{"options":["chatgpt","claude","perplexity"],"display":"header"},"navigation":{"global":{"anchors":[{"anchor":"Website","icon":"browser","href":"https://noxity.io"},{"anchor":"Community","icon":"discord","href":"https://discord.noxity.io"},{"anchor":"Linktree","icon":"bullseye-pointer","href":"https://tree.noxity.io"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@noxityio"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"noxity","hasAudioNarration":false,"actualSubdomain":"noxity","customDomains":["help.noxity.io"],"gitSource":{"type":"github","owner":"noxitylabs","repo":"knowledgebase","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6a78ab5b4caa9bc1ddd92dd8","collectionId":"4c19acc7-e123-4942-8877-bd13536bd445","schemaVersion":"v2","latestBuiltDeploymentHistoryId":"6a78ab5b4caa9bc1ddd92dd8"},"feedback":{"thumbs":true,"issues":false,"edits":false},"entitlements":{},"buildId":"6a78abf74caa9bc1ddd92e65:success","clientVersion":"0.0.4044","searchFilterCounts":[{"language":"default","tag":"English","count":228},{"language":"default","tag":"Web Hosting","count":106},{"language":"default","tag":"cPanel Control Panels","count":98},{"language":"default","tag":"Domains","count":52},{"language":"default","tag":"Registrations","count":33},{"language":"default","tag":"TLDs","count":25},{"language":"default","tag":"Members Area","count":21},{"language":"default","tag":"How To Guides","count":20},{"language":"default","tag":"Email Management","count":18},{"language":"default","tag":"Domain Management","count":15}]},"assistantConfig":{},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":true},"customCss":[{"filePath":"style.css","content":"html.dark{--shiki-dark-bg:#1A2436}html.dark .accordion,html.dark .code-block-background,html.dark .dark\\:bg-codeblock{background-color:#1a2436}html.dark .prose a:not(.not-prose):hover,html.dark a.link:not(.not-prose):hover{color:rgb(var(--primary-light)/1);border-bottom-color:rgb(var(--primary-light)/1)}html a.not-prose:hover{border-bottom-color:transparent!important}.mdx-content{z-index:22}html.dark .accordion:hover{border-color:rgb(var(--primary-light)/.45)}html.dark .accordion summary:hover{background-color:rgb(var(--primary-light)/.07)}html.dark .feedback-toolbar a,html.dark .feedback-toolbar button{background-color:#131a28;color:#d3cfd0;border-color:rgba(255,255,255,.07)}html.dark .feedback-toolbar a:hover,html.dark .feedback-toolbar button:hover{background-color:rgba(229,231,235,.05);border-color:rgba(255,255,255,.07);color:#e5e7eb}.kb-pill{display:inline-block;padding:5px 14px;margin:3px 4px 3px 0;border-radius:999px;border:1px solid rgba(0,0,0,.12);background-color:rgba(0,0,0,.03);color:#24292f;font-size:13px;font-weight:500;text-decoration:none!important;border-bottom:1px solid rgba(0,0,0,.12)!important;transition:all .15s ease}html.dark .kb-pill{border-color:rgba(255,255,255,.12);background-color:rgba(255,255,255,.04);color:#e5e7eb;border-bottom-color:rgba(255,255,255,.12)!important}.kb-pill:hover{border-color:rgb(var(--primary)/.5);background-color:rgb(var(--primary)/.08);color:rgb(var(--primary));border-bottom-color:rgb(var(--primary)/.5)!important}html.dark .kb-pill:hover{border-color:rgb(var(--primary-light)/.55);background-color:rgb(var(--primary-light)/.1);color:rgb(var(--primary-light));border-bottom-color:rgb(var(--primary-light)/.55)!important}"}],"page":{"pagePath":"web-hosting/virtual-containers/python","slug":"/web-hosting/virtual-containers/python","pageMetadata":{"title":"Python","description":"Set up a Python app in cPanel with Setup Python App. Pick an interpreter, point Passenger at your WSGI callable, and install packages with Run Pip Install.","icon":"python","keywords":["python","alt-python","python selector","setup python app","passenger","pip install","wsgi","django","flask","virtualenv"],"href":"/web-hosting/virtual-containers/python"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Set up a Python app in cPanel with Setup Python App. Pick an interpreter, point Passenger at your WSGI callable, and install packages with Run Pip Install.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{Accordion,AccordionGroup,Card,CardGroup,CodeBlock,Frame,Heading,Info,OptimizedImage,Step,Steps,Table,Warning}=_components;if(!Accordion)_missingMdxReference(`Accordion`,true);if(!AccordionGroup)_missingMdxReference(`AccordionGroup`,true);if(!Card)_missingMdxReference(`Card`,true);if(!CardGroup)_missingMdxReference(`CardGroup`,true);if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Frame)_missingMdxReference(`Frame`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Info)_missingMdxReference(`Info`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);if(!Step)_missingMdxReference(`Step`,true);if(!Steps)_missingMdxReference(`Steps`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(`div`,{className:`not-prose mint-mb-8 mint-pb-6 mint-border-b mint-border-gray-200 dark:mint-border-gray-800`,children:[_jsx(`div`,{className:`mint-mb-3 mint-text-sm mint-text-gray-500 dark:mint-text-gray-400`,children:_jsx(_components.p,{children:`Updated: August 9, 2026`})}),_jsxs(`div`,{className:`mint-flex mint-flex-wrap mint-items-center mint-gap-x-5 mint-gap-y-3`,children:[_jsxs(`div`,{className:`mint-flex mint-items-center mint-gap-3`,children:[_jsx(OptimizedImage,{src:`https://mintcdn.com/noxity/7AGDPHJNWXOTggDq/images/team/matic.png?fit=max\u0026auto=format\u0026n=7AGDPHJNWXOTggDq\u0026q=85\u0026s=236856f5898caae2ec034701c8cb2290`,alt:`Matic Bončina`,className:`mint-w-10 mint-h-10 mint-rounded-full mint-object-cover`,\"data-og-width\":`256`,width:`256`,\"data-og-height\":`256`,height:`256`,\"data-path\":`images/team/matic.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/noxity/7AGDPHJNWXOTggDq/images/team/matic.png?w=280\u0026fit=max\u0026auto=format\u0026n=7AGDPHJNWXOTggDq\u0026q=85\u0026s=8c85c59fdf3a3735fea6f05ea1be54b2 280w, https://mintcdn.com/noxity/7AGDPHJNWXOTggDq/images/team/matic.png?w=560\u0026fit=max\u0026auto=format\u0026n=7AGDPHJNWXOTggDq\u0026q=85\u0026s=081f83057fb24086dcba03a85efa3cd9 560w, https://mintcdn.com/noxity/7AGDPHJNWXOTggDq/images/team/matic.png?w=840\u0026fit=max\u0026auto=format\u0026n=7AGDPHJNWXOTggDq\u0026q=85\u0026s=b10e615d7615cafd06f262fc676b6913 840w, https://mintcdn.com/noxity/7AGDPHJNWXOTggDq/images/team/matic.png?w=1100\u0026fit=max\u0026auto=format\u0026n=7AGDPHJNWXOTggDq\u0026q=85\u0026s=a348763d27029aa8c314ec2ec1545689 1100w, https://mintcdn.com/noxity/7AGDPHJNWXOTggDq/images/team/matic.png?w=1650\u0026fit=max\u0026auto=format\u0026n=7AGDPHJNWXOTggDq\u0026q=85\u0026s=f8a35f42d49d0cf59250368250a2e0af 1650w, https://mintcdn.com/noxity/7AGDPHJNWXOTggDq/images/team/matic.png?w=2500\u0026fit=max\u0026auto=format\u0026n=7AGDPHJNWXOTggDq\u0026q=85\u0026s=0748e972f61065b371e472599c87afbe 2500w`}),_jsxs(`div`,{className:`mint-flex mint-flex-col mint-leading-tight`,children:[_jsx(`span`,{className:`mint-text-sm mint-text-gray-900 dark:mint-text-gray-100`,children:_jsxs(_components.p,{children:[`By `,_jsx(`strong`,{className:`mint-font-semibold`,children:`Matic Bončina`})]})}),_jsx(`span`,{className:`mint-text-sm mint-text-gray-500 dark:mint-text-gray-400`,children:_jsx(_components.p,{children:`Founder`})})]})]}),_jsx(`div`,{className:`mint-ml-auto`,children:_jsxs(`span`,{className:`mint-inline-flex mint-items-center mint-gap-1.5 mint-text-[11px] mint-tracking-wide mint-uppercase mint-font-semibold mint-px-2.5 mint-py-1 mint-rounded-full mint-bg-emerald-100 mint-text-emerald-700 dark:mint-bg-emerald-900 dark:mint-text-emerald-300`,children:[_jsx(`span`,{className:`mint-inline-flex mint-items-center mint-justify-center mint-w-3.5 mint-h-3.5 mint-rounded-full mint-border mint-border-current mint-text-[9px] mint-font-bold mint-leading-none`,children:_jsx(_components.p,{children:`✓`})}),_jsx(_components.p,{children:`Proofread \u0026 verified`})]})})]})]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Setup Python App`}),` registers a Python web application under your cPanel account. It builds a private virtualenv for the app, then hands the process to Phusion Passenger, which imports your WSGI callable and feeds it requests. You never start a server yourself.`]}),`\n`,_jsxs(_components.p,{children:[`The tool is CloudLinux’s Python Selector. Each app picks its own interpreter from the `,_jsx(_components.code,{children:`alt-python`}),` packages installed on the server, so two apps in one account can run different versions.`]}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[`Python is included on `,_jsx(_components.strong,{children:`BONFIRE`}),`, `,_jsx(_components.strong,{children:`BLAZE`}),` and `,_jsx(_components.strong,{children:`INFERMO`}),`. `,_jsx(_components.strong,{children:`SPARK`}),` and `,_jsx(_components.strong,{children:`FLAME`}),` don’t come with it, so those plans need an upgrade before `,_jsx(_components.strong,{children:`Setup Python App`}),` appears in cPanel.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`python-versions`,children:`Python versions`}),`\n`,_jsx(_components.p,{children:`Twelve interpreters are installed and available to pick from:`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`3.13.12`}),`, `,_jsx(_components.code,{children:`3.12.13`}),`, `,_jsx(_components.code,{children:`3.11.15`}),`, `,_jsx(_components.code,{children:`3.10.20`}),`, `,_jsx(_components.code,{children:`3.9.23`}),`, `,_jsx(_components.code,{children:`3.8.20`}),`, `,_jsx(_components.code,{children:`3.7.17`}),`, `,_jsx(_components.code,{children:`3.6.15`}),`, `,_jsx(_components.code,{children:`3.5.9`}),`, `,_jsx(_components.code,{children:`3.4.10`}),`, `,_jsx(_components.code,{children:`3.3.7`}),`, `,_jsx(_components.code,{children:`2.7.18`})]}),`\n`,_jsx(_components.p,{children:`Take the newest one your dependencies support. Everything below 3.9 is past upstream end of life and is there for old applications that can’t move yet.`}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsxs(_components.strong,{children:[`The version dropdown starts on `,_jsx(_components.code,{children:`2.7.18`}),`.`]}),` The Selector has no default version configured, so the form opens on the first entry in the list, which is Python 2. Create an app without touching that dropdown and you get a Python 2.7 virtualenv. Change it before you click `,_jsx(_components.strong,{children:`CREATE`}),`.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`set-up-an-app`,children:`Set up an app`}),`\n`,_jsxs(Steps,{children:[_jsxs(Step,{title:`Open Setup Python App`,children:[_jsxs(_components.p,{children:[`From cPanel home, scroll to `,_jsx(_components.strong,{children:`Software`}),` and click `,_jsx(_components.strong,{children:`Setup Python App`}),`.`]}),_jsx(Frame,{caption:`cPanel home → Software → Setup Python App`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/noxity/yZRC4X5johw34hA6/images/web-hosting/virtual-containers/python/open.png?fit=max\u0026auto=format\u0026n=yZRC4X5johw34hA6\u0026q=85\u0026s=2cf6c66229ab8ec4bc6f17fb8eb83142`,alt:`The Software section of cPanel home, with Setup Python App in the third row beside Setup Node.js App and Setup Ruby App`,\"data-og-width\":`1966`,width:`1966`,\"data-og-height\":`632`,height:`632`,\"data-path\":`images/web-hosting/virtual-containers/python/open.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/noxity/yZRC4X5johw34hA6/images/web-hosting/virtual-containers/python/open.png?w=280\u0026fit=max\u0026auto=format\u0026n=yZRC4X5johw34hA6\u0026q=85\u0026s=e515a210a1c04b083c2c5a6d31895626 280w, https://mintcdn.com/noxity/yZRC4X5johw34hA6/images/web-hosting/virtual-containers/python/open.png?w=560\u0026fit=max\u0026auto=format\u0026n=yZRC4X5johw34hA6\u0026q=85\u0026s=7731a3a5a08a8c1b70baac2bad130f88 560w, https://mintcdn.com/noxity/yZRC4X5johw34hA6/images/web-hosting/virtual-containers/python/open.png?w=840\u0026fit=max\u0026auto=format\u0026n=yZRC4X5johw34hA6\u0026q=85\u0026s=99a7538261396f3a6237547d4184f3e0 840w, https://mintcdn.com/noxity/yZRC4X5johw34hA6/images/web-hosting/virtual-containers/python/open.png?w=1100\u0026fit=max\u0026auto=format\u0026n=yZRC4X5johw34hA6\u0026q=85\u0026s=6fdd08e68f68cb89e6cf216aa29d8817 1100w, https://mintcdn.com/noxity/yZRC4X5johw34hA6/images/web-hosting/virtual-containers/python/open.png?w=1650\u0026fit=max\u0026auto=format\u0026n=yZRC4X5johw34hA6\u0026q=85\u0026s=5d44fa3c39edf49afbd7956f5595b3b1 1650w, https://mintcdn.com/noxity/yZRC4X5johw34hA6/images/web-hosting/virtual-containers/python/open.png?w=2500\u0026fit=max\u0026auto=format\u0026n=yZRC4X5johw34hA6\u0026q=85\u0026s=7b8dfd78c6fafa1273f78b1c77802a5a 2500w`})})]}),_jsx(Step,{title:`Click CREATE APPLICATION`,children:_jsxs(_components.p,{children:[`On an account with no apps yet, the page shows `,_jsx(_components.strong,{children:`WEB APPLICATIONS`}),` and `,_jsx(_components.strong,{children:`NO APPLICATIONS FOUND`}),`. Click `,_jsx(_components.strong,{children:`CREATE APPLICATION`}),` to open the form.`]})}),_jsxs(Step,{title:`Fill in the form`,children:[_jsx(_components.p,{children:`Five fields, plus an environment variable panel:`}),_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Python version`}),`: change it off `,_jsx(_components.code,{children:`2.7.18`}),` unless you really want Python 2.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Application root`}),`: the directory holding your code, relative to your home directory, such as `,_jsx(_components.code,{children:`myapp`}),`. This is the only mandatory field.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Application URL`}),`: pick a domain, then add a path if you want one. Leave the path box empty to serve the app at the domain root.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Application startup file`}),`: the file Passenger imports, usually `,_jsx(_components.code,{children:`passenger_wsgi.py`}),`. The field starts empty and there is no default, so type it in.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Application Entry point`}),`: the name of the WSGI callable inside that file. cPanel describes it as “Setup wsgi callable object for your application”. The usual answer is `,_jsx(_components.code,{children:`application`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Environment variables`}),`: click `,_jsx(_components.strong,{children:`ADD VARIABLE`}),` for anything your app reads from the environment.`]}),`\n`]}),_jsx(Frame,{caption:`Setup Python App → CREATE APPLICATION`,children:_jsx(OptimizedImage,{src:`https://mintcdn.com/noxity/LQMi0tm90yR8XVhO/images/web-hosting/virtual-containers/python/create-form.png?fit=max\u0026auto=format\u0026n=LQMi0tm90yR8XVhO\u0026q=85\u0026s=190bc8ba40cd2e8e7c8b5ab15208d8bb`,alt:`The create form with the Python version dropdown sitting on 2.7.18, an empty Application root marked as a mandatory field, the Application URL domain picker, and empty Application startup file and Application Entry point fields`,\"data-og-width\":`3840`,width:`3840`,\"data-og-height\":`2160`,height:`2160`,\"data-path\":`images/web-hosting/virtual-containers/python/create-form.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/noxity/LQMi0tm90yR8XVhO/images/web-hosting/virtual-containers/python/create-form.png?w=280\u0026fit=max\u0026auto=format\u0026n=LQMi0tm90yR8XVhO\u0026q=85\u0026s=a8c534097c64211299b110a929691653 280w, https://mintcdn.com/noxity/LQMi0tm90yR8XVhO/images/web-hosting/virtual-containers/python/create-form.png?w=560\u0026fit=max\u0026auto=format\u0026n=LQMi0tm90yR8XVhO\u0026q=85\u0026s=e24c456f769cc70bb0d3aaa224990c28 560w, https://mintcdn.com/noxity/LQMi0tm90yR8XVhO/images/web-hosting/virtual-containers/python/create-form.png?w=840\u0026fit=max\u0026auto=format\u0026n=LQMi0tm90yR8XVhO\u0026q=85\u0026s=bb01f9e20422329cf20acd7b312d6c62 840w, https://mintcdn.com/noxity/LQMi0tm90yR8XVhO/images/web-hosting/virtual-containers/python/create-form.png?w=1100\u0026fit=max\u0026auto=format\u0026n=LQMi0tm90yR8XVhO\u0026q=85\u0026s=2b1496f72338385ff75260a209d12373 1100w, https://mintcdn.com/noxity/LQMi0tm90yR8XVhO/images/web-hosting/virtual-containers/python/create-form.png?w=1650\u0026fit=max\u0026auto=format\u0026n=LQMi0tm90yR8XVhO\u0026q=85\u0026s=e1c56bc959b4911217e66aed2274e4cc 1650w, https://mintcdn.com/noxity/LQMi0tm90yR8XVhO/images/web-hosting/virtual-containers/python/create-form.png?w=2500\u0026fit=max\u0026auto=format\u0026n=LQMi0tm90yR8XVhO\u0026q=85\u0026s=77d1edb6f7beb90242d6b3280ef35778 2500w`})})]}),_jsx(Step,{title:`Click CREATE`,children:_jsx(_components.p,{children:`The Selector creates the app root, builds the virtualenv, and switches to the management view for the new app. You’ll see the activation command for its virtualenv at the top of that page.`})})]}),`\n`,_jsx(Heading,{level:`2`,id:`what-gets-created`,children:`What gets created`}),`\n`,_jsxs(_components.p,{children:[`Creating an app writes three things into your application root: a `,_jsx(_components.code,{children:`public`}),` directory, a `,_jsx(_components.code,{children:`tmp`}),` directory holding `,_jsx(_components.code,{children:`restart.txt`}),`, and a placeholder `,_jsx(_components.code,{children:`passenger_wsgi.py`}),`. Replace that placeholder with your own file.`]}),`\n`,_jsxs(_components.p,{children:[`The virtualenv lands outside the app root, at `,_jsx(_components.code,{children:`~/virtualenv/\u003capp-root>/\u003cmajor.minor>/`}),`. An app on 3.13.12 gets `,_jsx(_components.code,{children:`~/virtualenv/myapp/3.13/`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`manage-an-app`,children:`Manage an app`}),`\n`,_jsx(_components.p,{children:`Opening an existing app shows the same fields you filled in, now with controls across the top and extra panels below.`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Control`}),_jsx(_components.th,{children:`What it does`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`STOP APP`})}),_jsx(_components.td,{children:`Stops the running application.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`RESTART`})}),_jsxs(_components.td,{children:[`Restarts it. Passenger also restarts on its own when the timestamp on `,_jsx(_components.code,{children:`tmp/restart.txt`}),` changes.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`SAVE`})}),_jsx(_components.td,{children:`Applies changes you made to the fields on this page.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`DESTROY`})}),_jsx(_components.td,{children:`Unregisters the app and deletes its virtualenv. Your application directory and files stay.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`OPEN`})}),_jsx(_components.td,{children:`Opens the application URL in a new tab.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Run Pip Install`})}),_jsxs(_components.td,{children:[`Installs from a requirements file you list under `,_jsx(_components.strong,{children:`Configuration files`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Run Script`})}),_jsxs(_components.td,{children:[`Runs a Python script in the app’s environment, such as `,_jsx(_components.code,{children:`manage.py migrate`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`ADD VARIABLE`})}),_jsx(_components.td,{children:`Adds an environment variable.`})]})]})]}),`\n`,_jsxs(_components.p,{children:[`There is no separate Edit button. The management page is the form, so change a field and click `,_jsx(_components.strong,{children:`SAVE`}),`.`]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`DESTROY leaves your files behind.`}),` It removes the Passenger registration and deletes `,_jsx(_components.code,{children:`~/virtualenv/\u003capp-root>/`}),`, but the application directory itself, including your code, `,_jsx(_components.code,{children:`tmp/`}),`, and any log files, stays exactly where it was. Delete it in File Manager if you want it gone.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`the-passenger-contract`,children:`The Passenger contract`}),`\n`,_jsxs(_components.p,{children:[`Passenger doesn’t run your file as a script. It imports the file named in `,_jsx(_components.strong,{children:`Application startup file`}),` and looks for the callable named in `,_jsx(_components.strong,{children:`Application Entry point`}),`. With the usual pairing of `,_jsx(_components.code,{children:`passenger_wsgi.py`}),` and `,_jsx(_components.code,{children:`application`}),`, that means a top-level name `,_jsx(_components.code,{children:`application`}),` has to exist.`]}),`\n`,_jsx(_components.p,{children:`For Flask:`}),`\n`,_jsx(CodeBlock,{filename:`passenger_wsgi.py`,numberOfLines:`1`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` myapp `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` app `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`as`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` application`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`For Django:`}),`\n`,_jsx(CodeBlock,{filename:`passenger_wsgi.py`,numberOfLines:`8`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`8`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` os`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` sys`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`sys.path.insert(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, os.path.dirname(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#9CDCFE`},children:`__file__`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`))`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`os.environ.setdefault(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'DJANGO_SETTINGS_MODULE'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'myapp.settings'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` django.core.wsgi `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` get_wsgi_application`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`application `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` get_wsgi_application()`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Your code does not start a development server. No `,_jsx(_components.code,{children:`app.run()`}),`, no `,_jsx(_components.code,{children:`manage.py runserver`}),`. Passenger owns the process and the socket.`]}),`\n`,_jsx(Heading,{level:`2`,id:`asgi-apps`,children:`ASGI apps`}),`\n`,_jsxs(_components.p,{children:[`Passenger speaks WSGI. FastAPI, Starlette and Django Channels are ASGI, so they need a bridge in front of them. `,_jsx(_components.a,{href:`https://pypi.org/project/a2wsgi/`,children:`a2wsgi`}),` provides one:`]}),`\n`,_jsx(CodeBlock,{filename:`passenger_wsgi.py`,numberOfLines:`4`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`4`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` a2wsgi `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ASGIMiddleware`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` main `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` app `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`as`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` asgi_app`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`application `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ASGIMiddleware(asgi_app)`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`That covers ordinary request and response traffic. WebSockets and long-lived streaming don’t survive the translation, because WSGI has no model for them. If you need those, you need a process listening on its own port, which this tool doesn’t provide. Open a ticket and we’ll talk through the options.`}),`\n`,_jsx(Heading,{level:`2`,id:`reference-where-things-live`,children:`Reference: where things live`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`What`}),_jsx(_components.th,{children:`Path`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Virtualenv`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`~/virtualenv/\u003capp-root>/\u003cmajor.minor>/`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Installed packages`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`~/virtualenv/\u003capp-root>/\u003cmajor.minor>/lib/`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Restart trigger`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`~/\u003capp-root>/tmp/restart.txt`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Startup file`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`~/\u003capp-root>/\u003cyour startup file>`})})]})]})]}),`\n`,_jsxs(_components.p,{children:[`The management page prints the exact command for entering the environment from SSH. For an app rooted at `,_jsx(_components.code,{children:`myapp`}),` on 3.13:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`2`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`source`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` ~/virtualenv/myapp/3.13/bin/activate`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` \u0026\u0026 `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`cd`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` ~/myapp`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`pip`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` install`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -r`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` requirements.txt`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`common-issues`,children:`Common issues`}),`\n`,_jsxs(AccordionGroup,{children:[_jsx(Accordion,{title:`The app booted on Python 2.7 and I didn't ask for it`,id:`the-app-booted-on-python-2-7-and-i-didnt-ask-for-it`,children:_jsxs(_components.p,{children:[`The version dropdown opens on `,_jsx(_components.code,{children:`2.7.18`}),` and stays there unless you change it, so an app created in a hurry ends up on Python 2. Check the `,_jsx(_components.strong,{children:`Python version`}),` field on the management page, set the one you wanted, and click `,_jsx(_components.strong,{children:`SAVE`}),`. Reinstall your packages afterwards with `,_jsx(_components.strong,{children:`Run Pip Install`}),`, since the environment your app uses is tied to the interpreter.`]})}),_jsx(Accordion,{title:`Passenger can't find an application callable`,id:`passenger-cant-find-an-application-callable`,children:_jsxs(_components.p,{children:[`The name in `,_jsx(_components.strong,{children:`Application Entry point`}),` has to exist as a top-level name in the file named in `,_jsx(_components.strong,{children:`Application startup file`}),`. If your Flask object is called `,_jsx(_components.code,{children:`app`}),`, either rename it or alias it: `,_jsx(_components.code,{children:`application = app`}),`. Check both fields on the management page before you go digging through your code.`]})}),_jsx(Accordion,{title:`ImportError on a package you just installed`,id:`importerror-on-a-package-you-just-installed`,children:_jsxs(_components.p,{children:[`The package went into the system Python rather than the app’s virtualenv. Use `,_jsx(_components.strong,{children:`Run Pip Install`}),` from the management page, or activate the environment first in SSH with the command that page prints.`]})}),_jsx(Accordion,{title:`Django static files return 404`,id:`django-static-files-return-404`,children:_jsxs(_components.p,{children:[`Passenger serves the WSGI application and nothing else, so `,_jsx(_components.code,{children:`/static/`}),` isn’t handled for you. Run `,_jsx(_components.code,{children:`collectstatic`}),` and serve the output as ordinary files. The `,_jsx(_components.a,{href:`/how-to/virtual-containers/python/django`,children:`Deploy Django`}),` guide walks through the layout.`]})}),_jsx(Accordion,{title:`A pip install fails partway through`,id:`a-pip-install-fails-partway-through`,children:_jsxs(_components.p,{children:[`Memory is rarely the culprit. Plans that include Python start at 6 GB of RAM on BONFIRE and reach 12 GB on INFERMO, which is comfortably enough for prebuilt wheels like `,_jsx(_components.code,{children:`pandas`}),` or `,_jsx(_components.code,{children:`numpy`}),`. The more common trigger is a package with no wheel for the interpreter you chose, which drops pip into a source build. Check which version the app is on first, then send us the pip output if it still won’t install.`]})}),_jsx(Accordion,{title:`A cold boot times out`,id:`a-cold-boot-times-out`,children:_jsx(_components.p,{children:`Passenger’s documented default gives an application 90 seconds to start before it gives up and logs an error. Slow migrations or heavy imports at module level can run past that. Move that work out of startup, or open a ticket and we’ll look at the boot log with you.`})})]}),`\n`,_jsx(Heading,{level:`2`,id:`recipes`,children:`Recipes`}),`\n`,_jsxs(CardGroup,{cols:2,children:[_jsx(Card,{title:`Deploy Django`,icon:`layer-group`,href:`/how-to/virtual-containers/python/django`,children:`Django app, virtualenv, static files.`}),_jsxs(Card,{title:`Deploy Flask`,icon:`flask`,href:`/how-to/virtual-containers/python/flask`,children:[`Flask service via `,_jsx(_components.code,{children:`passenger_wsgi.py`}),`.`]})]}),`\n`,_jsx(Heading,{level:`2`,id:`need-a-hand`,children:`Need a hand?`}),`\n`,_jsxs(CardGroup,{cols:2,children:[_jsx(Card,{title:`Open a ticket`,icon:`life-ring`,href:`https://members.noxity.io/submitticket.php`,children:_jsx(_components.p,{children:`Best for anything that needs an account check or a config change on our end.`})}),_jsx(Card,{title:`Live chat`,icon:`messages`,href:`https://noxity.io/contact`,children:_jsx(_components.p,{children:`Faster for quick questions during business hours.`})})]}),`\n`,_jsx(`div`,{className:`mint-mt-8`,children:_jsx(Accordion,{title:`Sources`,icon:`book-bookmark`,id:`sources`,children:_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`/web-hosting/virtual-containers/overview`,children:`Virtual Containers overview`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`/how-to/virtual-containers/python/django`,children:`Deploy Django`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`/how-to/virtual-containers/python/flask`,children:`Deploy Flask`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://noxity.io/web-hosting`,children:`Noxity web hosting plan comparison ↗`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://docs.cloudlinux.com/cloudlinuxos/cloudlinux_os_components/#python-selector`,children:`CloudLinux Python Selector ↗`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://www.phusionpassenger.com/library/config/apache/reference/`,children:`Passenger Apache configuration reference ↗`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://www.phusionpassenger.com/library/admin/apache/restart_app.html`,children:`Restarting a Passenger application ↗`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://asgi.readthedocs.io/en/latest/introduction.html`,children:`ASGI introduction ↗`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://pypi.org/project/a2wsgi/`,children:`a2wsgi on PyPI ↗`})}),`\n`]})})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":{},"config":{},"pageMetadata":{"title":"Python","description":"Set up a Python app in cPanel with Setup Python App. Pick an interpreter, point Passenger at your WSGI callable, and install packages with Run Pip Install.","icon":"python","keywords":["python","alt-python","python selector","setup python app","passenger","pip install","wsgi","django","flask","virtualenv"],"href":"/web-hosting/virtual-containers/python"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Python versions","slug":"python-versions","depth":2,"children":[]},{"title":"Set up an app","slug":"set-up-an-app","depth":2,"children":[]},{"title":"What gets created","slug":"what-gets-created","depth":2,"children":[]},{"title":"Manage an app","slug":"manage-an-app","depth":2,"children":[]},{"title":"The Passenger contract","slug":"the-passenger-contract","depth":2,"children":[]},{"title":"ASGI apps","slug":"asgi-apps","depth":2,"children":[]},{"title":"Reference: where things live","slug":"reference-where-things-live","depth":2,"children":[]},{"title":"Common issues","slug":"common-issues","depth":2,"children":[]},{"title":"Recipes","slug":"recipes","depth":2,"children":[]},{"title":"Need a hand?","slug":"need-a-hand","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"dynamicCss":".mint-mb-3 {\n margin-bottom: 0.75rem\n}\n.mint-mb-8 {\n margin-bottom: 2rem\n}\n.mint-ml-auto {\n margin-left: auto\n}\n.mint-mt-8 {\n margin-top: 2rem\n}\n.mint-flex {\n display: flex\n}\n.mint-inline-flex {\n display: inline-flex\n}\n.mint-h-10 {\n height: 2.5rem\n}\n.mint-h-3\\.5 {\n height: 0.875rem\n}\n.mint-w-10 {\n width: 2.5rem\n}\n.mint-w-3\\.5 {\n width: 0.875rem\n}\n.mint-flex-col {\n flex-direction: column\n}\n.mint-flex-wrap {\n flex-wrap: wrap\n}\n.mint-items-center {\n align-items: center\n}\n.mint-justify-center {\n justify-content: center\n}\n.mint-gap-1\\.5 {\n gap: 0.375rem\n}\n.mint-gap-3 {\n gap: 0.75rem\n}\n.mint-gap-x-5 {\n column-gap: 1.25rem\n}\n.mint-gap-y-3 {\n row-gap: 0.75rem\n}\n.mint-rounded-full {\n border-radius: 9999px\n}\n.mint-border {\n border-width: 1px\n}\n.mint-border-b {\n border-bottom-width: 1px\n}\n.mint-border-current {\n border-color: currentColor\n}\n.mint-border-gray-200 {\n --tw-border-opacity: 1;\n border-color: rgb(229 231 235 / var(--tw-border-opacity, 1))\n}\n.mint-bg-emerald-100 {\n --tw-bg-opacity: 1;\n background-color: rgb(209 250 229 / var(--tw-bg-opacity, 1))\n}\n.mint-object-cover {\n object-fit: cover\n}\n.mint-px-2\\.5 {\n padding-left: 0.625rem;\n padding-right: 0.625rem\n}\n.mint-py-1 {\n padding-top: 0.25rem;\n padding-bottom: 0.25rem\n}\n.mint-pb-6 {\n padding-bottom: 1.5rem\n}\n.mint-text-\\[11px\\] {\n font-size: 11px\n}\n.mint-text-\\[9px\\] {\n font-size: 9px\n}\n.mint-text-sm {\n font-size: 0.875rem;\n line-height: 1.25rem\n}\n.mint-font-bold {\n font-weight: 700\n}\n.mint-font-semibold {\n font-weight: 600\n}\n.mint-uppercase {\n text-transform: uppercase\n}\n.mint-leading-none {\n line-height: 1\n}\n.mint-leading-tight {\n line-height: 1.25\n}\n.mint-tracking-wide {\n letter-spacing: 0.025em\n}\n.mint-text-emerald-700 {\n --tw-text-opacity: 1;\n color: rgb(4 120 87 / var(--tw-text-opacity, 1))\n}\n.mint-text-gray-500 {\n --tw-text-opacity: 1;\n color: rgb(107 114 128 / var(--tw-text-opacity, 1))\n}\n.mint-text-gray-900 {\n --tw-text-opacity: 1;\n color: rgb(17 24 39 / var(--tw-text-opacity, 1))\n}\n.dark\\:mint-border-gray-800:is(.dark *) {\n --tw-border-opacity: 1;\n border-color: rgb(31 41 55 / var(--tw-border-opacity, 1))\n}\n.dark\\:mint-bg-emerald-900:is(.dark *) {\n --tw-bg-opacity: 1;\n background-color: rgb(6 78 59 / var(--tw-bg-opacity, 1))\n}\n.dark\\:mint-text-emerald-300:is(.dark *) {\n --tw-text-opacity: 1;\n color: rgb(110 231 183 / var(--tw-text-opacity, 1))\n}\n.dark\\:mint-text-gray-100:is(.dark *) {\n --tw-text-opacity: 1;\n color: rgb(243 244 246 / var(--tw-text-opacity, 1))\n}\n.dark\\:mint-text-gray-400:is(.dark *) {\n --tw-text-opacity: 1;\n color: rgb(156 163 175 / var(--tw-text-opacity, 1))\n}","subdomain":"noxity","siteName":"Noxity Knowledgebase","title":"Python - Noxity Knowledgebase","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-08-09T08:37:48.121Z","originalFileLocation":"web-hosting/virtual-containers/python.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=\"dark\";if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Set up a Python app in cPanel with Setup Python App. Pick an interpreter, point Passenger at your WSGI callable, and install packages with Run Pip Install.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Noxity Knowledgebase\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/noxity/LKaJSIbrz-d1OdkS/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/noxity/LKaJSIbrz-d1OdkS/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/noxity/LKaJSIbrz-d1OdkS/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/noxity/LKaJSIbrz-d1OdkS/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/noxity/LKaJSIbrz-d1OdkS/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/noxity/LKaJSIbrz-d1OdkS/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/noxity/LKaJSIbrz-d1OdkS/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/noxity/LKaJSIbrz-d1OdkS/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/noxity/LKaJSIbrz-d1OdkS/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Python - Noxity Knowledgebase\">\u003cmeta data-mint-head property=\"og:description\" content=\"Set up a Python app in cPanel with Setup Python App. Pick an interpreter, point Passenger at your WSGI callable, and install packages with Run Pip Install.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Noxity Knowledgebase\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://help.noxity.io/web-hosting/virtual-containers/python\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://noxity.mintlify.app/_mintlify/api/og/v2?division=Virtual+Containers\u0026amp;title=Python\u0026amp;description=Set+up+a+Python+app+in+cPanel+with+Setup+Python+App.+Pick+an+interpreter%2C+point+Passenger+at+your+WSGI+callable%2C+and+install+packages+with+Run+Pip+Install.\u0026amp;theme=d51555184c0af4aba17159e6\u0026amp;signature=4a48613977a929afa466422b72b5202b48a98627f9072de2d3a1297264aacba5\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Python - Noxity Knowledgebase\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Set up a Python app in cPanel with Setup Python App. Pick an interpreter, point Passenger at your WSGI callable, and install packages with Run Pip Install.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://noxity.mintlify.app/_mintlify/api/og/v2?division=Virtual+Containers\u0026amp;title=Python\u0026amp;description=Set+up+a+Python+app+in+cPanel+with+Setup+Python+App.+Pick+an+interpreter%2C+point+Passenger+at+your+WSGI+callable%2C+and+install+packages+with+Run+Pip+Install.\u0026amp;theme=d51555184c0af4aba17159e6\u0026amp;signature=4a48613977a929afa466422b72b5202b48a98627f9072de2d3a1297264aacba5\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/noxity/LKaJSIbrz-d1OdkS/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Noxity Knowledgebase\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#B83553\">\u003clink data-mint-head rel=\"canonical\" href=\"https://help.noxity.io/web-hosting/virtual-containers/python\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/web-hosting/virtual-containers/python.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://help.noxity.io/#organization\",\"name\":\"Noxity Knowledgebase\",\"url\":\"https://help.noxity.io\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/noxity/AKndteo9-AwoOj4e/logo/dark.png?fit=max\u0026auto=format\u0026n=AKndteo9-AwoOj4e\u0026q=85\u0026s=76f2b0618a4cdbd4376d51ddab0477f0\"}},{\"@type\":\"WebSite\",\"@id\":\"https://help.noxity.io#website\",\"name\":\"Noxity Knowledgebase\",\"url\":\"https://help.noxity.io\",\"publisher\":{\"@id\":\"https://help.noxity.io/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://help.noxity.io/web-hosting/virtual-containers/python#webpage\",\"url\":\"https://help.noxity.io/web-hosting/virtual-containers/python\",\"name\":\"Python\",\"description\":\"Set up a Python app in cPanel with Setup Python App. Pick an interpreter, point Passenger at your WSGI callable, and install packages with Run Pip Install.\",\"dateModified\":\"2026-08-09T08:37:48.121Z\",\"isPartOf\":{\"@id\":\"https://help.noxity.io#website\"},\"breadcrumb\":{\"@id\":\"https://help.noxity.io/web-hosting/virtual-containers/python#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://help.noxity.io/web-hosting/virtual-containers/python#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Virtual Containers\",\"item\":\"https://help.noxity.io/web-hosting/virtual-containers/overview\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Python\",\"item\":\"https://help.noxity.io/web-hosting/virtual-containers/python\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://help.noxity.io/web-hosting/virtual-containers/python#article\",\"headline\":\"Python\",\"name\":\"Python\",\"description\":\"Set up a Python app in cPanel with Setup Python App. Pick an interpreter, point Passenger at your WSGI callable, and install packages with Run Pip Install.\",\"url\":\"https://help.noxity.io/web-hosting/virtual-containers/python\",\"mainEntityOfPage\":{\"@id\":\"https://help.noxity.io/web-hosting/virtual-containers/python#webpage\"},\"dateModified\":\"2026-08-09T08:37:48.121Z\",\"keywords\":\"python, alt-python, python selector, setup python app, passenger, pip install, wsgi, django, flask, virtualenv\",\"publisher\":{\"@id\":\"https://help.noxity.io/#organization\"},\"isPartOf\":{\"@id\":\"https://help.noxity.io#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Noxity Knowledgebase\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Noxity Knowledgebase","nav":{"global":{"anchors":[{"anchor":"Website","icon":"browser","href":"https://noxity.io"},{"anchor":"Community","icon":"discord","href":"https://discord.noxity.io"},{"anchor":"Linktree","icon":"bullseye-pointer","href":"https://tree.noxity.io"},{"anchor":"YouTube","icon":"youtube","href":"https://www.youtube.com/@noxityio"}]},"products":[{"product":"Getting Started","icon":"rocket-launch","pages":[{"title":"Getting Started","href":"/welcome"}]},{"product":"Documentation","icon":"file-lines","dropdowns":[{"dropdown":"English","icon":"flag","tabs":[{"tab":"Web Hosting","icon":"globe","groups":[{"group":"cPanel Control Panels","pages":[{"title":"cPanel","icon":"cpanel","href":"/web-hosting/overview"},{"group":"File Management","icon":"cabinet-filing","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"cabinet-filing","href":"/web-hosting/cpanel/file-management/overview"},{"title":"File Manager","icon":"folder-tree","href":"/web-hosting/cpanel/file-management/file-manager"},{"title":"Images","icon":"image","href":"/web-hosting/cpanel/file-management/images"},{"title":"Directory Privacy","icon":"lock","href":"/web-hosting/cpanel/file-management/directory-privacy"},{"title":"Disk Usage","icon":"hard-drive","href":"/web-hosting/cpanel/file-management/disk-usage"},{"title":"Web Disk","icon":"cloud","href":"/web-hosting/cpanel/file-management/web-disk"},{"title":"Git Version Control","icon":"code-branch","href":"/web-hosting/cpanel/file-management/git-version-control"},{"title":"JetBackup","icon":"dragon","href":"/web-hosting/cpanel/file-management/jetbackup"}]},{"group":"Email Management","icon":"envelopes","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"envelopes","href":"/web-hosting/cpanel/email-management/overview"},{"title":"Email Accounts","icon":"at","href":"/web-hosting/cpanel/email-management/email-accounts"},{"title":"Forwarders","icon":"share-from-square","href":"/web-hosting/cpanel/email-management/forwarders"},{"title":"Email Routing","icon":"route","href":"/web-hosting/cpanel/email-management/email-routing"},{"title":"Autoresponders","icon":"reply","href":"/web-hosting/cpanel/email-management/autoresponders"},{"title":"Default Address","icon":"at","href":"/web-hosting/cpanel/email-management/default-address"},{"title":"Mailing Lists","icon":"list","href":"/web-hosting/cpanel/email-management/mailing-lists"},{"title":"Track Delivery","icon":"magnifying-glass-chart","href":"/web-hosting/cpanel/email-management/track-delivery"},{"title":"Global Email Filters","icon":"filter-circle-xmark","href":"/web-hosting/cpanel/email-management/global-email-filters"},{"title":"Email Filters","icon":"filter","href":"/web-hosting/cpanel/email-management/email-filters"},{"title":"Email Deliverability","icon":"circle-check","href":"/web-hosting/cpanel/email-management/email-deliverability"},{"title":"Address Importer","icon":"file-import","href":"/web-hosting/cpanel/email-management/address-importer"},{"title":"Spam Filters","icon":"ban","href":"/web-hosting/cpanel/email-management/spam-filters"},{"title":"Encryption","icon":"key","href":"/web-hosting/cpanel/email-management/encryption"},{"title":"BoxTrapper","icon":"shield-halved","href":"/web-hosting/cpanel/email-management/boxtrapper"},{"title":"Calendars and Contacts","icon":"calendar-days","href":"/web-hosting/cpanel/email-management/calendars-and-contacts"},{"title":"Email Disk Usage","icon":"chart-pie","href":"/web-hosting/cpanel/email-management/email-disk-usage"},{"title":"Mail Clients","icon":"mailbox","href":"/web-hosting/cpanel/email-management/mail-clients"}]},{"group":"Database Management","icon":"database","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"database","href":"/web-hosting/cpanel/database-management/overview"},{"title":"Manage My Databases","icon":"database","href":"/web-hosting/cpanel/database-management/manage-databases"},{"title":"Database Wizard","icon":"hat-wizard","href":"/web-hosting/cpanel/database-management/database-wizard"},{"title":"Remote Database Access","icon":"network-wired","href":"/web-hosting/cpanel/database-management/remote-database-access"},{"group":"phpMyAdmin","icon":"user-helmet-safety","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"user-helmet-safety","href":"/web-hosting/cpanel/database-management/phpmyadmin/overview"},{"title":"Browse Tables and Data","icon":"table","href":"/web-hosting/cpanel/database-management/phpmyadmin/browse"},{"title":"Run SQL Queries","icon":"terminal","href":"/web-hosting/cpanel/database-management/phpmyadmin/sql"},{"title":"Table Operations","icon":"screwdriver-wrench","href":"/web-hosting/cpanel/database-management/phpmyadmin/table-operations"},{"title":"Import a Database","icon":"file-import","href":"/web-hosting/cpanel/database-management/phpmyadmin/import"},{"title":"Export a Database","icon":"file-export","href":"/web-hosting/cpanel/database-management/phpmyadmin/export"}]}]},{"group":"Domain Management","icon":"galaxy","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"galaxy","href":"/web-hosting/cpanel/domain-management/overview"},{"title":"Domains","icon":"diagram-subtask","href":"/web-hosting/cpanel/domain-management/domains"},{"title":"Redirects","icon":"share-from-square","href":"/web-hosting/cpanel/domain-management/redirects"},{"title":"Zone Editor","icon":"spider-web","href":"/web-hosting/cpanel/domain-management/zone-editor"},{"title":"Dynamic DNS","icon":"arrows-rotate","href":"/web-hosting/cpanel/domain-management/dynamic-dns"},{"group":"WordPress Management","icon":"wordpress","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"wordpress","href":"/web-hosting/cpanel/domain-management/wordpress-management/overview"},{"title":"Installations","icon":"list","href":"/web-hosting/cpanel/domain-management/wordpress-management/installations"},{"title":"Site management","icon":"screwdriver-wrench","href":"/web-hosting/cpanel/domain-management/wordpress-management/site-management"},{"title":"Plugins","icon":"plug","href":"/web-hosting/cpanel/domain-management/wordpress-management/plugins"},{"title":"Themes","icon":"palette","href":"/web-hosting/cpanel/domain-management/wordpress-management/themes"}]}]},{"group":"Metrics \u0026 Analytics","icon":"chart-mixed","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"chart-mixed","href":"/web-hosting/cpanel/metrics-analytics/overview"},{"title":"Visitors","icon":"user","href":"/web-hosting/cpanel/metrics-analytics/visitors"},{"title":"Errors","icon":"circle-exclamation","href":"/web-hosting/cpanel/metrics-analytics/errors"},{"title":"Bandwidth","icon":"gauge","href":"/web-hosting/cpanel/metrics-analytics/bandwidth"},{"title":"Raw Access","icon":"file-zipper","href":"/web-hosting/cpanel/metrics-analytics/raw-access"},{"title":"Awstats","icon":"wave-pulse","href":"/web-hosting/cpanel/metrics-analytics/awstats"},{"title":"Analog Stats","icon":"chart-line","href":"/web-hosting/cpanel/metrics-analytics/analog-stats"},{"title":"Webalizer","icon":"chart-waterfall","href":"/web-hosting/cpanel/metrics-analytics/webalizer"},{"title":"Webalizer FTP","icon":"folder-tree","href":"/web-hosting/cpanel/metrics-analytics/webalizer-ftp"},{"title":"Metrics Editor","icon":"sliders","href":"/web-hosting/cpanel/metrics-analytics/metrics-editor"},{"title":"Resource Usage","icon":"gauge-high","href":"/web-hosting/cpanel/metrics-analytics/resource-usage"}]},{"group":"Security Settings","icon":"tower-observation","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"tower-observation","href":"/web-hosting/cpanel/security-settings/overview"},{"title":"SSH Access","icon":"terminal","href":"/web-hosting/cpanel/security-settings/ssh-access"},{"title":"IP Blocker","icon":"ban","href":"/web-hosting/cpanel/security-settings/ip-blocker"},{"title":"Manage API Tokens","icon":"key","href":"/web-hosting/cpanel/security-settings/manage-api-tokens"},{"title":"Hotlink Protection","icon":"link-slash","href":"/web-hosting/cpanel/security-settings/hotlink-protection"},{"title":"Leech Protection","icon":"user-lock","href":"/web-hosting/cpanel/security-settings/leech-protection"},{"title":"ModSecurity","icon":"shield-halved","href":"/web-hosting/cpanel/security-settings/modsecurity"},{"group":"SSL/TLS Certificates","icon":"file-certificate","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"file-certificate","href":"/web-hosting/cpanel/security-settings/ssl-tls-certificates/overview"},{"title":"Wizard","icon":"wand-magic-sparkles","href":"/web-hosting/cpanel/security-settings/ssl-tls-certificates/wizard"},{"title":"Status","icon":"signal-bars","href":"/web-hosting/cpanel/security-settings/ssl-tls-certificates/status"},{"title":"Certificates","icon":"file-certificate","href":"/web-hosting/cpanel/security-settings/ssl-tls-certificates/certificates"},{"title":"Keys","icon":"key","href":"/web-hosting/cpanel/security-settings/ssl-tls-certificates/keys"},{"title":"Requests","icon":"signature","href":"/web-hosting/cpanel/security-settings/ssl-tls-certificates/requests"},{"title":"Installation","icon":"plug","href":"/web-hosting/cpanel/security-settings/ssl-tls-certificates/installation"},{"title":"Settings","icon":"sliders","href":"/web-hosting/cpanel/security-settings/ssl-tls-certificates/settings"}]},{"group":"Imunify360","icon":"shield-virus","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"shield-virus","href":"/web-hosting/cpanel/security-settings/imunify360/overview"}]}]},{"group":"Software","icon":"computer","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"code","href":"/web-hosting/cpanel/software/overview"},{"title":"PHP PEAR Packages","icon":"cubes-stacked","href":"/web-hosting/cpanel/software/pear-packages"},{"title":"Perl Modules","icon":"gem","href":"/web-hosting/cpanel/software/perl-modules"},{"title":"Optimize Website","icon":"gauge","href":"/web-hosting/cpanel/software/optimize-website"},{"group":"Select PHP Version","icon":"php","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"php","href":"/web-hosting/cpanel/software/select-php-version/overview"},{"title":"Extensions","icon":"puzzle-piece","href":"/web-hosting/cpanel/software/select-php-version/extensions"},{"title":"Options","icon":"sliders","href":"/web-hosting/cpanel/software/select-php-version/options"}]},{"group":"AccelerateWP","icon":"bolt","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"bolt","href":"/web-hosting/cpanel/software/accelerate-wp/overview"},{"title":"Caching","icon":"database","href":"/web-hosting/cpanel/software/accelerate-wp/caching"},{"title":"File optimization","icon":"scissors","href":"/web-hosting/cpanel/software/accelerate-wp/file-optimization"},{"title":"Media optimization","icon":"image","href":"/web-hosting/cpanel/software/accelerate-wp/media-optimization"},{"title":"Database and Heartbeat","icon":"broom-wide","href":"/web-hosting/cpanel/software/accelerate-wp/database-and-heartbeat"}]},{"title":"X-Ray App","icon":"magnifying-glass-chart","href":"/web-hosting/cpanel/software/php-xray"},{"group":"Softaculous","icon":"browser","pages":[{"title":"Karkoli","href":"/web-hosting/cpanel/software/softaculous/softaculous-example"}]},{"group":"Website Builder","icon":"forklift","pages":[{"title":"Karkoli","href":"/web-hosting/cpanel/software/website-builder/website-builder-example"}]}]},{"group":"Advanced","icon":"gears","pages":[{"title":"Overview","sidebarTitle":"Overview","icon":"gears","href":"/web-hosting/cpanel/advanced/overview"},{"title":"LiteSpeed Redis Cache Manager","icon":"database","href":"/web-hosting/cpanel/advanced/litespeed-redis-cache-manager"},{"title":"LiteSpeed Web Cache Manager","icon":"bolt","href":"/web-hosting/cpanel/advanced/litespeed-web-cache-manager"},{"title":"Cron Jobs","icon":"calendar-clock","href":"/web-hosting/cpanel/advanced/cron-jobs"},{"title":"Terminal","icon":"terminal","href":"/web-hosting/cpanel/advanced/terminal"},{"title":"Track DNS","icon":"compass","href":"/web-hosting/cpanel/advanced/track-dns"},{"title":"Indexes","icon":"list-tree","href":"/web-hosting/cpanel/advanced/indexes"},{"title":"Error Pages","icon":"triangle-exclamation","href":"/web-hosting/cpanel/advanced/error-pages"},{"title":"Apache Handlers","icon":"feather","href":"/web-hosting/cpanel/advanced/apache-handlers"},{"title":"MIME Types","icon":"file-code","href":"/web-hosting/cpanel/advanced/mime-types"},{"title":"Virus Scanner","icon":"shield-virus","href":"/web-hosting/cpanel/advanced/virus-scanner"}]}]},{"group":"Virtual Containers","icon":"container-storage","pages":[{"title":"Virtual Containers","icon":"container-storage","href":"/web-hosting/virtual-containers/overview"},{"title":"Node.js","description":"Run Node.js apps on cPanel via the Node.js Selector. Pick a version, set the application root, and let Passenger start the process.","icon":"node","href":"/web-hosting/virtual-containers/nodejs"},{"title":"Python","icon":"python","href":"/web-hosting/virtual-containers/python"},{"title":"Ruby","description":"Set up a Ruby app in cPanel with the Ruby Selector. Pick a Ruby version per app, point it at a directory and a URL.","icon":"gem","href":"/web-hosting/virtual-containers/ruby"}]}]},{"tab":"Domains","icon":"plane-up","pages":[{"title":"Domains","href":"/domains/overview"}]},{"tab":"Members Area","icon":"user-astronaut","pages":[{"title":"Members Area","href":"/members/members"}]}]},{"dropdown":"Slovenščina","icon":"flag","pages":[{"title":"Dobrodošli","icon":"meteor","href":"/sl/welcome"}]}]},{"product":"Knowledge Base","icon":"book-open-cover","pages":[{"title":"Knowledge Base","href":"/how-to/how-to-example"}]}]},"basePath":"","title":"Python - Noxity Knowledgebase","buildId":"dpl_DeHjVRGfFnhYQwHnfC2pjeXXv8h9","deploymentId":"dpl_DeHjVRGfFnhYQwHnfC2pjeXXv8h9","dynamics":["a74be98ba7","07c022d89b"],"chunks":["zoom-image-lightbox-BG6oD64b.js","lightbox-handle-r17bVUz3.js","Frame-DXXFP6nH.js","DynamicMarkdown-B54_zNBF.js"]}