Deploy MongoDB on Your VPS
Deploy MongoDB on your VPS in one click. Document-oriented NoSQL database, pinned to the last fully-open-source 6.x line.
MongoDB is the most popular document database — schema-flexible, JSON-native, and the default choice for Node.js / Express / TypeScript stacks. Vessl ships the official Mongo 6 image with persistent storage, an auto-generated root credential, and an initial database created on first boot.
The 6.x line is intentional: it is the last fully open-source release before the SSPL re-licensing. Pin to 6 keeps you free of the cloud-restriction clauses; bump deliberately if your workload needs 7.x time-series collections or Atlas-specific features.
What's included
- Persistent volume for /data/db so collections survive redeploys
- Auto-generated root username + password as environment variables
- Initial database created from the deploy form
- Internal-only network exposure — no public Mongo port
- Compatible with every Mongo driver: Mongoose, MongoDB Node Driver, mgo, pymongo, etc.
Common use cases
- Document store for Node.js / TypeScript applications
- Schema-flexible storage for content management or user-generated data
- Self-hosted alternative to MongoDB Atlas for cost-sensitive workloads
Frequently asked questions
Why MongoDB 6 instead of the latest 7.x?
MongoDB 6 is the last release before the Server Side Public License (SSPL) terms tightened. Self-hosters who care about license clarity stay on 6; teams that need 7.x features can pin a different tag in the deploy form.
How does my application connect?
Both services share the project network. Reference Mongo by its service name and port 27017 — connection string ends up like mongodb://user:pass@vessl-svc-id:27017/dbname.
Can I run a replica set?
The default deploy is a standalone instance. For replica sets, deploy three Mongo services and configure rs.initiate() manually — same way you would on any self-hosted Docker installation.
Ready to ship?
Deploy MongoDB in under a minute.
Connect your VPS, pick this template, fill in any required fields. Vessl handles the container, SSL, and persistent storage.
Start for FreeNo credit card · BYOS · IDR billing
