Hosting for FastAPI and Python APIs
Need stable HTTPS for FastAPI, a webhook, or a Mini App backend? Upload the project — Deployka picks up Python, dependencies, and the start command. Logs and restart stay in the dashboard.
What this page covers
- uvicorn / gunicorn
- PORT and 0.0.0.0
- requirements.txt
- health check
- webhook + logs + restart
How to deploy
- ZIP or GitHub with requirements.txt / pyproject.toml and an entrypoint (uvicorn / gunicorn).
- Set ENV (secrets, DATABASE_URL) — we configure PORT automatically.
- Deploy → install deps → process listens on PORT → HTTPS URL + logs.
ENV you need
- PORT — your uvicorn/--port (or env) must use it.
- API keys, BOT_TOKEN, DATABASE_URL — dashboard secrets.
- CORS / ALLOWED_ORIGINS — if the frontend is on another domain.
Package managers and stack
- pip + requirements.txt
- Poetry / pip-tools — when the lockfile is clear to the builder
Common failures
- ModuleNotFoundError — deps missing from requirements or the environment was not reproduced.
- Connection refused / health check failed — the app is not listening on 0.0.0.0:$PORT.
- Crash on boot from ENV — Deploy Doctor flags missing keys before the build.
Pricing
Small API — Node Micro / similar plans from 299 ₽/mo. Heavier FastAPI / Mini App backends — MVP App at 1190 ₽/mo.
Code ready. Deployka runs it.