Docs
Hangar documentation
How Hangar builds, deploys and runs your apps and databases: guides and reference for every part of the platform.
- QuickstartDeploy your first app on Hangar, from a Git repository or your AI agent to a public URL with HTTPS, in a few minutes.
- Git providersConnect your Git host to Hangar once, choose which repositories it can see, and deploy any branch from them on every push.
- AI agents (MCP)Connect Claude Code, Cursor or any MCP client to Hangar so your AI agent can deploy, read build and runtime logs, metrics and traces, and change settings.
- Migrate from RailwayMove a Railway project to Hangar with your AI agent over MCP or by hand, with its services, variables, databases and domains, keeping Railway running until the switch.
Build and deploy
- BuildsHow Hangar turns a repository into a running container, the builders you can choose from and when to use each one.
- Deploy a Docker imageRun a prebuilt Docker image on Hangar from Docker Hub, GHCR or a private registry, and redeploy it from your CI with a deploy hook.
- Docker ComposeDeploy a docker-compose.yml on Hangar from your repository or pasted in, as Docker Compose on one node or as a Swarm stack across the region.
- Deployments and rollbacksHow Hangar deploys a service, how to trigger a deploy from your CI with a deploy hook, and how to roll back to an earlier release in seconds.
- Preview deploymentsDeploy every GitHub pull request to its own URL on Hangar, with its own variables, and remove it automatically when the pull request closes.
- Cron jobsRun a Hangar service on a cron schedule instead of keeping it up, for reports, cleanups and syncs, billed only while each run lasts.
Configuration
- Environment variablesSet configuration and secrets for a Hangar service, and share values across services with project and environment variables.
- Domains and HTTPSGive a Hangar service a public address, on a generated domain or your own, with a TLS certificate issued and renewed for you.
- Deploy on Hangar buttonAdd a button to your README that lets anyone deploy your repository on Hangar in one click.
- hangar.yaml deploy manifestDescribe the services, databases, volumes and variables a Deploy on Hangar link creates, in a hangar.yaml file at the root of your repository.
Databases and storage
- DatabasesCreate a managed PostgreSQL, MySQL, MariaDB, MongoDB, Redis or libSQL database on Hangar and connect it to your app.
- Connect to a database from outsideTurn on public networking to reach a Hangar database from your laptop, a BI tool or another cloud through its own TCP proxy address.
- VolumesKeep files across deploys on Hangar with a persistent volume, attach it to any service, and back it up on a schedule or every 15 minutes.
- Backups and point-in-time recoveryProtect Hangar databases with point-in-time recovery to any second, scheduled dumps to your own S3 bucket, and restores that never overwrite your data.