Investbrain is an investment tracker that consolidates several brokerage accounts into a single dashboard: what you hold, what it cost, what it is worth now, and how the whole thing has performed over time. It is built in PHP on Laravel and ships as a Docker Compose stack – the application container plus PostgreSQL and Redis – so it runs on a home server or NAS as readily as on a VPS. There is also a hosted version at investbra.in if you would rather not operate a server.
The design assumption is that your transactions are the source of truth. You record what you bought and sold, and the app derives positions, cost basis, gains and performance from that history rather than asking you to keep a spreadsheet of balances in step with reality.
Work is organised around a portfolio, typically one per brokerage account – a workplace pension, a Robinhood account, a self-managed ISA. Each portfolio holds transactions: a single buy or sell of a security on a given date, with quantity, price and fees. From those, Investbrain generates holdings automatically, so a position’s quantity and average cost are never typed in by hand and can never drift out of step with the trade log.
A portfolio can be flagged as a wishlist – a watchlist of ideas you model with hypothetical transactions but keep out of your real totals and performance figures. Dividends and stock splits are tracked separately from ordinary trades, so income and adjusted basis stay visible instead of being folded into a single return number.
The dashboard rolls up every portfolio you can see, wishlists excluded. A performance chart can be switched between market value, cost basis and market gain, over ranges from one month to all time; longer ranges thin to one point per week, then one per month, each taken from the last trading day of the period. Five summary cards sit above it – market gain or loss, total cost basis, total market value, realised gain or loss, and dividends earned – expressed in a display currency you choose. Below them come top performers and a recent-activity feed, and a single portfolio page repeats the same cards and chart scoped to that account.
Prices, fundamentals, dividend history and splits come from an external provider. Self-hosted instances pick one, or list several for automatic fallback (Yahoo Finance first, then Finnhub, then Alpha Vantage, for example). Yahoo Finance is the default and needs no key; Twelve Data, Finnhub, Alpaca and Alpha Vantage are supported with their own keys, and the provider interface is documented if you want to write another.
A Provider Health page reports call volume, success rate, fallback rate and average response time over the last day, week or month, with a per-provider breakdown and the most recent failures – which is the difference between noticing Yahoo has started rate-limiting you and quietly watching stale prices. It is visible only to the first account registered on the instance.
An optional chat panel on portfolio and holding pages answers questions about what you actually own, with the current position and performance in context. It is off by default. Point it at Anthropic or any OpenAI-compatible endpoint – including a local Ollama instance – with three environment variables, and the same window appears on every portfolio page. The panel carries a standing disclaimer that generated advice may be wrong.
A portfolio can be shared by email with read-only or full access, which covers the spouse, the accountant or the financial adviser without handing over an account. Invitations arrive by email once SMTP is configured. Data moves in and out as well: full backups for moving between instances, and bulk transaction import from a spreadsheet for the tedious part of getting started.
There is a REST API with tokens for scripting against your own instance, and an MCP server so assistants such as Claude, ChatGPT or an editor-side agent can query the portfolio through the same authorization model. Two-factor authentication and social logins are available for the account itself.
The supported install is the project’s own compose file: download it, set APP_URL and change DB_PASSWORD, then docker compose up -d and register at /register. First start runs the migrations and can take a few minutes. Three named volumes hold the storage, the PostgreSQL data and the Redis queue, so upgrades are a pull and a restart. Registration can be switched off once your own account exists and further users invited by portfolio sharing. A minimum of one reachable market-data provider is required for holdings to show prices at all.
Investbrain is published under the Creative Commons Attribution-NonCommercial 4.0 International licence, not an OSI-approved open-source licence. The source code is public and you may run, modify and share it, but the NonCommercial term means commercial use is not permitted under the licence as published, and attribution is required. If you need to run a portfolio tracker inside a business, check the terms with the project first.