
Self-hosting Mage AI the easy way
Yulei ChenMage AI is an open-source data pipeline tool that lets you build, run, and manage ETL/ELT workflows. It supports dbt integrations, real-time streaming, and comes with a visual pipeline editor. While Mage offers a managed cloud version, self-hosting gives you full control over your data and no usage limits.
Sliplane makes self-hosting painless. With one-click deployment, you can get Mage AI up and running in minutes - no server setup, no reverse proxy, no infrastructure headaches.
Prerequisites
Before deploying, ensure you have a Sliplane account (free trial available).
Quick start
Sliplane provides one-click deployment with presets.
- Click the deploy button above
- Select a project
- Select a server (If you just signed up you get a 48-hour free trial server)
- Click Deploy!
About the preset
The one-click deploy above uses Sliplane's Mage AI preset. Here is what it includes:
- Official
mageai/mageaiDocker image (version 0.9.79) - Starts the default project automatically via
mage start default_project - Persistent storage mounted to
/home/srcso your pipelines and project files survive restarts - Production mode enabled via
ENV=production - User authentication enabled by default (built into Mage AI 0.9.78+) with a pre-generated owner account
- Listens on port 6789
Signing in
Once Mage AI is running, open the domain Sliplane assigned (e.g. mageai-xxxx.sliplane.app) in your browser. You will be greeted by a sign-in page.
The preset creates an owner account for you automatically. The credentials are pre-set as environment variables on your service:
| Variable | Default value |
|---|---|
DEFAULT_OWNER_EMAIL | admin@admin.com |
DEFAULT_OWNER_USERNAME | admin |
DEFAULT_OWNER_PASSWORD | randomly generated |
Open your service in the Sliplane dashboard, go to Environment Variables, and copy the value of DEFAULT_OWNER_PASSWORD. Use it together with the email above to sign in. We strongly recommend changing the password from the user management page (/settings/workspace/users) after your first login.
Heads up: these defaults only take effect on the very first start, when no owner exists yet. Changing the variables later will not update the credentials of the already-created user — use the user management page instead.
Next steps
Key environment variables
Here are some useful environment variables you can set in your service settings:
| Variable | Description | Default |
|---|---|---|
PROJECT_NAME | Name of the Mage project | default_project |
ENV | Runtime environment (production, dev, test) | production |
DEFAULT_OWNER_EMAIL | Email of the auto-created owner user | admin@admin.com |
DEFAULT_OWNER_USERNAME | Username of the auto-created owner user | admin |
DEFAULT_OWNER_PASSWORD | Password of the auto-created owner user | randomly generated |
MAGE_ACCESS_TOKEN_EXPIRY_TIME | Access token lifetime in seconds | 2592000 (30 days) |
DISABLE_NOTEBOOK_EDIT_ACCESS | Prevent code editing in the UI | 0 (disabled) |
For the full list, see the Mage AI authentication docs.
Logging
Mage AI logs to STDOUT by default, which works perfectly with Sliplane's built-in log viewer. If you need to debug pipeline issues, check the logs in your Sliplane dashboard. For general Docker log tips, see our post on how to use Docker logs.
Troubleshooting
If the service takes a while to become healthy, that is normal. Mage AI can need 30-60 seconds to fully start, especially on smaller servers. If it stays unhealthy, check the logs for errors related to missing dependencies or port conflicts.
Cost comparison
You can also self-host Mage AI with other cloud providers. Here is a pricing comparison for the most common ones:
| Provider | vCPU | RAM | Disk | Monthly Cost | Note |
|---|---|---|---|---|---|
| Sliplane | 2 | 2 GB | 40 GB | €9 (~$10.65) | Flat rate, 1 TB bandwidth, SSL included |
| Fly.io | 2 | 2 GB | 40 GB | ~$18 | Disk and bandwidth billed separately |
| Render | 1 | 2 GB | 40 GB | ~$35 | 100 GB bandwidth, Disk billed separately |
| Railway | 2 | 2 GB | 40 GB | ~$67 + $20 plan | Pro plan floor, usage-based, bandwidth billed separately |
Click here to see how these numbers were calculated.
(Assuming an always-on instance running 730 hrs/month)
- Sliplane: flat €9/month for the Base server. Unlimited services on the same server, 1 TB egress and SSL included.
- Fly.io:
shared-cpu-2x2 GB = $11.83/mo + 40 GB volume × $0.15/GB = $6 -> ~$17.83/mo. Egress billed separately ($0.02/GB in EU). - Render: closest match is Standard ($25, 1 vCPU / 2 GB) plus 40 GB disk × $0.25/GB = $10 -> ~$35/mo. Stepping up to Pro (2 vCPU / 4 GB) costs $85/mo + disk.
- Railway (Pro plan): CPU 2 × $0.00000772/s × 2,628,000 s = $40.57; RAM 2 × $0.00000386/s × 2,628,000 s = $20.29; volume 40 × $0.00000006/s × 2,628,000 s = $6.31 -> ~$67/mo compute, plus the $20/mo Pro plan floor and $0.05/GB egress.
Bandwidth costs can add up fast on usage-based providers. Use our bandwidth cost comparison tool to see what your egress would cost on each platform.
FAQ
What can I build with Mage AI?
Mage AI is designed for data engineering workflows. You can build ETL/ELT pipelines, schedule data transformations, integrate with dbt, stream data in real-time, and connect to databases, data warehouses, and APIs. It is a great fit for teams that need a visual pipeline editor without paying for expensive managed solutions.
How do I connect Mage AI to a database?
In the Mage AI UI, go to the pipeline editor and add a data loader or data exporter block. Mage supports PostgreSQL, MySQL, BigQuery, Snowflake, Redshift, and many more out of the box. If your database runs on the same Sliplane server, use the internal service name as the host (e.g. postgres.internal). You can also store connection details in Mage's IO config for reuse across pipelines.
How do I update Mage AI?
Change the image tag in your Sliplane service settings to the new version and redeploy. Check Docker Hub for the latest stable version. Your project files and pipelines are stored on the persistent volume, so they will not be affected by the update.
Are there alternatives to Mage AI?
Yes. Popular alternatives include n8n (workflow automation with 400+ integrations), Langflow (AI-focused low-code builder), Apache Airflow (the industry-standard pipeline orchestrator), and Prefect (modern Python-native orchestration). Each has different strengths depending on whether you need general automation, AI workflows, or pure data engineering.
Can I use dbt with Mage AI?
Yes. Mage AI has built-in dbt integration. You can add dbt models as blocks in your pipelines, run dbt commands directly from the UI, and manage your dbt project alongside your other pipeline code. See the Mage dbt docs for setup instructions.