Running on Galaxy Legacy? Visit the legacy docs.
Galaxy

MongoDB

Create and manage MongoDB databases on Galaxy with automatic backups and zero transfer fees.

MongoDB on Galaxy

Create and manage MongoDB databases on Galaxy with automatic backups and zero transfer fees.

Free MongoDB Available

Galaxy offers a free MongoDB tier perfect for development and learning. Free databases have usage limits to ensure fair access for everyone. Learn about storage limits and when to upgrade in our Fair Usage Policy for Free MongoDB.


Create a MongoDB Database

Getting a MongoDB database running takes about two minutes.

Open Your Dashboard

Go to your Galaxy dashboard and click Databases in the sidebar.

Start Database Creation

Click Create Database and select MongoDB as your database type.

Configure Your Instance

Choose your MongoDB version and instance size. Pick the region closest to your app for best performance.

Create and Wait

Click Create Database & Start Billing. Galaxy provisions your database in a few minutes. You'll see "Running" when it's ready.

Same Region = Best Performance

Deploy your database in the same region as your app. This minimizes latency and keeps your data transfer free.


Connect to Your App

Click your database in the dashboard to see the connection string. Copy it and add it as an environment variable in your app's settings.

The exact variable name depends on your framework:

  • Meteor apps: Use MONGO_URL
  • Node.js apps: Typically MONGODB_URL or DATABASE_URL
  • Other frameworks: Check your framework's documentation for the expected variable name

Keep Your Connection String Secure

Never hardcode your connection string in your code. Always use environment variables so it stays secure and out of version control.


Features

Automatic Backups: Daily backups included with all plans. Your data is protected without you lifting a finger.

Replica Sets Available: High availability option for production apps. Your data is replicated across multiple nodes, so if one goes down, others keep running.

Zero Transfer Fees: Data moving between your Galaxy app and database is free. No surprise charges on your bill.


Common Questions


What's Next?