# Railway Database
```{admonition} Too complicated? Not what you're looking for? :class: seealso Consider a hosted Nightscout service! Check for easier solutions [here](/index.md#nightscout-as-a-service). ```
```{danger} The free plan has been removed Jul 3rd for new users and Aug 1st for existing users.
Documentation will be updated to reflect the changes when visible. ```
```{card} ## Railway Mongo Database ![Railway](/vendors/img/Railway.png) ![MongoDB](/vendors/img/MongoDB.png) ^^^ Railway offers a Mongo database. **Pros**: * Simple to create * Less overhead than Atlas (more space) * Mongo database cost is $0.000231/GB/Minute **Cons**: * You need to carefully monitor your database size and clean it up regularly to remain within the Hobby plan 5$/month limits * Simple Mongo 4.4 database ```
## Create a Railway account If you already have a Railway account, make sure you have a developper plan: go to **step g)**.
a) Open [Railway](https://railway.app) in a new browser tab and click `login`. Type your email and select `Email`.
b) Leave the browser open on this screen
c) Check your email (look also in the spam folder) and click on the `Authorize Railway App`.
d) Type the code you had in **b)**.
e) Close this tab and return to the one you left open in **b)**.
f) Click on `Please agree to the new terms to keep on using Railway`.
d) Scroll down and click `I agree with Railway's Terms of Service`.
e) Scroll down and click `I will not deploy any of that`.
f) You should now see this. You've created your Railway account.
g) Upgrade your account to a Developer plan. Click on the `Unverified` and select `Remove Resource Limits`.
```{danger} The free plan will be removed Jul 3rd for new users and Aug 1st for existing users.
Documentation will be updated to reflect the changes when visible. ``` Enter your credit card information and select `Subscribe to a Hobby Plan`. Your card will be billed 1$ that will be refund immediately. Bank fees won't be refund.
## Create your database a) Click `New Project` from your Dashboard screen (top right).
b) Click `Provision MongoDB`
c) Select your new MongoDB project.
d) Go to the `Connect` page.
e) Scroll down to `Available Variables`, move the mouse to the end of the line showing the `MONGO_URL` and click the copy icon.
```{admonition} This is an important information :class: warning Now that you have **copied** the resulting `MONGODB_URI` string, keep it in a **safe place**, you will need it later. ```