---
title: "Deploy Ghostfolio"
description: "Self-hosted Ghostfolio: track stocks, ETFs and crypto wealth"
category: "Analytics"
url: https://railway.com/deploy/ghostfolio-2
---

# Deploy Ghostfolio

Self-hosted Ghostfolio: track stocks, ETFs and crypto wealth

**[Deploy Ghostfolio on Railway](https://railway.com/template/ghostfolio-2)**

Machine-readable deploy manifest (JSON, validated by TemplateCI): https://railway.com/deploy/ghostfolio-2/manifest.json

- **Creator:** INAPP
- **Category:** Analytics

## Template content

### ghostfolio

- **Source:** https://github.com/INAPP-Mobile/ghostfolio
- **Health check:** /api/v1/health
- **Public domain:** Yes

### postgres

- **Source:** https://github.com/INAPP-Mobile/ghostfolio

### redis

- **Source:** https://github.com/INAPP-Mobile/ghostfolio

## Documentation

[![Deploy on Railway](https://railway.app/button.svg)](https://railway.com/deploy/ghostfolio-2?utm_campaign=ghostfolio)

![Ghostfolio dashboard — upstream screenshot](https://raw.githubusercontent.com/INAPP-Mobile/ghostfolio/main/assets/screenshot.png)

Screenshot: upstream's own dashboard screenshot (ghostfolio/ghostfolio, AGPL-3.0), showing the portfolio overview with holdings and performance.

# Deploy and Host

Ghostfolio is an open-source wealth management platform for tracking stocks, ETFs, cryptocurrencies, bonds, and cash across every broker and exchange in one private dashboard — net worth, performance attribution, dividends, and risk, with your transaction history staying in your own database. With 50,000+ stars and a release cadence of several versions a month, it is the maintained, self-hosted alternative to Sharesight and Mint.

What gets deployed:

- **ghostfolio** — Angular client + NestJS API in one container (port 3333); runs Prisma migrations on every boot
- **postgres** — PostgreSQL 16 companion, data on a Railway volume
- **redis** — Redis 8 companion, response cache + BullMQ job queues for market-data refreshes

The deploy form has two generated fields — an access-token salt and a JWT secret — and nothing else to fill in. On first visit, click Get Started, save the one-time security token, and you are the admin; close public sign-ups afterwards in Settings → Self-Hosting.

## About Hosting

Three services from the official image (ghostfolio/ghostfolio v3.100.0, pinned by digest, AGPL-3.0). Railway's injected `PORT` is honored natively — the app binds `0.0.0.0:$PORT` on every boot. The public URL is derived from the live domain at boot, and the healthcheck is `/api/v1/health` (unauthenticated, 200 when Postgres and Redis are both healthy). All persistent state lives in Postgres; the app service is stateless, so holdings, accounts, and transactions survive redeploys.

## Why Deploy

- **Zero-fuss start:** no setup wizard, no email step — one click, one token, you are the admin.
- **Real portfolio tracking:** accounts, activities, dividends, liabilities, budgets, and a full REST API, with prices from Yahoo Finance by default — no API key needed.
- **Always-on by design:** the app, Postgres, and Redis run continuously, so scheduled price refreshes and snapshots happen without a second deploy.
- **Private by default:** holdings never leave infrastructure you control; Ghostfolio only fetches public market data and never moves money or touches broker credentials.

## Common Use Cases

- Replace Sharesight, Mint, or a spreadsheet with a private net-worth dashboard across brokers, banks, and wallets.
- Track dividends, fees, and performance per account, asset, and tag — and export everything as CSV or JSON.
- Feed a budgeting app or a personal dashboard from Ghostfolio's full REST API.
- Watch a watchlist of symbols with daily price history, without handing holdings to a third-party tracker.

## Dependencies for

Everything this template provisions, and how each piece is configured:

### Deployment Dependencies

| Setting | Value |
|---|---|
| Runtime | Ghostfolio v3.100.0 (Node 22, NestJS + Angular) + PostgreSQL 16 + Redis 8 |
| Plan | Hobby; three services |
| Port | Railway's injected `PORT`, honored natively on every boot (default 3333) |
| Persistence | One Railway volume at `/var/lib/postgresql/data` (Postgres data); one at `/data` (Redis append-only file); app service stateless |
| Healthcheck | `/api/v1/health` (unauthenticated, 200); the app is ready when Postgres and Redis both answer |

| Variable | Value | Notes |
|---|---|---|
| `ACCESS_TOKEN_SALT`, `JWT_SECRET_KEY` | `${{secret(32)}}` each | Generated on the deploy form; both must stay stable across redeploys. |
| `POSTGRES_*` | user/db `ghostfolio`, password generated | Auto-wired: `POSTGRES_HOST` is `${{postgres.RAILWAY_PRIVATE_DOMAIN}}`, password is `${{postgres.POSTGRES_PASSWORD}}`; `DATABASE_URL` is composed at boot from them. |
| `REDIS_*` | host auto-wired, port `6379` | `REDIS_HOST` is `${{redis.RAILWAY_PRIVATE_DOMAIN}}`; no password (private network only, same as upstream's compose). |
| `API_KEY_COINGECKO_DEMO` | _(empty, optional)_ | Optional CoinGecko demo key; lifts the 365-day crypto history limit. |

Baked or derived internals: `TRUST_PROXY=true`, `HOST=0.0.0.0`, `ROOT_URL` derived at boot from the live public domain. Other upstream variables (CoinGecko Pro, Alpha Vantage, EODHD, OIDC) can be added after deploy — see the [upstream self-hosting docs](https://ghostfol.io/en/faq/self-hosting).


## Similar templates

- [Plausible WordPress](https://railway.com/deploy/deploy-plausible-for-wordpress-sites) — Cookie-free WordPress stats from your own Plausible
- [Typesense Multilingual](https://railway.com/deploy/deploy-typesense-multilingual-search) — Locale-aware multilingual search with Typesense
- [Formbricks](https://railway.com/deploy/formbricks-surveys) — Surveys, NPS and in-app feedback on your own Postgres, Hub and Cube

Open this page in a browser: https://railway.com/deploy/ghostfolio-2
