Cryptofolio
A crypto portfolio tracker with live prices and risk-free demo trading.
- Personal project
- Full Stack Developer
- Personal
Client and context
Cryptofolio is a crypto portfolio platform where users track assets and practise trading without risking real money.
Problem
Investors needed one calm view of their holdings and a safe way to test a strategy, without a heavy backend or balances that drift out of sync.
What I built
- A Next.js 14 frontend on Vercel and an Express REST API on Render (MVC), with MongoDB through Mongoose.
- Live prices from the CoinGecko API and TradingView charts, loaded in the browser to keep the backend lean.
- A virtual demo-trading engine: every user starts with $10,000, and holdings are computed by replaying buy/sell history.
- JWT auth with bcrypt, Helmet security headers and rate limiting.
Results
- Live on Vercel and Render. Holdings are always computed from the recorded trades, so they cannot drift.
How it works
Architecture
A monorepo with separate client/ and server/ directories. The client is a Next.js 14 App Router frontend on Vercel; the server is an Express REST API on Render with an MVC structure (models → routes → controllers) and MongoDB through Mongoose. CoinGecko prices and TradingView charts load straight into the browser to keep the backend lean.
The demo trading engine
Instead of storing a balance that can drift out of sync, every buy and sell is an immutable transaction in MongoDB. Current holdings and portfolio value are computed by replaying that history, so the portfolio is always a provable function of what the user actually did.
Security
The API is treated as a public surface: JWT authentication with bcrypt-hashed passwords, Helmet security headers and express-rate-limit (20 requests a minute) on the endpoints.
Stack
- Next.js 14
- Express
- MongoDB
- JWT
- CoinGecko API