A zero-dependency, multi-chain EVM portfolio watcher — CLI + a small local web dashboard.
Track your wallets across Ethereum, BNB Smart Chain, Base, Arbitrum, Optimism, and Polygon. Native balances + well-known ERC-20s, priced live via CoinGecko. No dependencies, no keys, no transactions — it only reads public balances.
Screenshot placeholder — run
chainfolio serveand open http://localhost:3000 to see your own dashboard.
git clone https://github.com/noone52/chainfolio.git
cd chainfolio
# 1. Create your config from the example (public addresses only!)
cp config/wallets.example.json config/wallets.json
# 2. Edit config/wallets.json with your wallet addresses
# 3. Run it
npm start # snapshot in the terminal
# or
node src/cli.js snapshot --format jsonRequires Node.js ≥ 20. No npm install needed — there are no dependencies.
⚠️ Never put private keys, seed phrases, or API secrets inconfig/wallets.json. chainfolio only needs your public wallet addresses to read balances. It never signs anything.
| Command | What it does |
|---|---|
chainfolio snapshot |
Fetch balances + prices, print a table |
chainfolio snapshot --format json |
Same, as JSON |
chainfolio snapshot --chain base |
Only one chain |
chainfolio export --format csv --output out.csv |
Write a snapshot to a file |
chainfolio watch --interval 120 |
Poll every 120s, alert on big moves / price thresholds |
chainfolio serve --port 3000 |
Local dashboard at http://localhost:3000 |
config/wallets.json:
{
"wallets": [
{
"address": "0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045",
"label": "vitalik.eth",
"chains": ["ethereum", "base", "arbitrum"],
"costBasisUsd": 5000
}
],
"settings": { "includeTokens": true, "minUsdToShow": 0.01 },
"alerts": {
"changePct": 5,
"priceThresholds": { "ETH": { "above": 5000, "below": 1000 } }
}
}chainsis optional — omit it to watch all six chains.costBasisUsdis optional — set it to see PnL.minUsdToShowhides dust below that value.
| Chain | Native | Tokens tracked |
|---|---|---|
| Ethereum | ETH | USDT, USDC, WETH, DAI, WBTC, LINK |
| BNB Smart Chain | BNB | USDT, USDC, WBNB, CAKE, ETH |
| Base | ETH | USDC, WETH, cbETH, DAI |
| Arbitrum One | ETH | USDT, USDC, WETH, ARB |
| Optimism | ETH | USDT, USDC, WETH, OP, DAI |
| Polygon | POL | USDT, USDC.e, WETH, WMATIC, DAI |
Token addresses are the canonical deployments — verify on the chain explorer before relying on them for large sums. Add your own in src/tokens.js.
eth_getBalancefor native assets,eth_call(balanceOf)for ERC-20s, via public RPCs.- Prices in one batched CoinGecko request, cached for 60 seconds.
- Amount × price, grouped by chain and token, PnL vs. your cost basis.
- Rendered as a terminal table, JSON, CSV, or the web dashboard.
A chain that fails is skipped and listed under ERRORS — one bad RPC never kills the whole snapshot. Missing prices show as n/a, never as a fake number. See docs/ARCHITECTURE.md.
- Custom token lists per wallet (add any ERC-20 by address)
- Historical snapshots + charts (SQLite, still zero-dep via
node:sqliteon Node 22+) - Telegram / webhook alerts in
watchmode - More chains (Solana via RPC, zkSync, Linea)
- Price source fallback (CoinGecko → DeFiLlama)
Does it need my private key? No — never. Public addresses only, read-only RPC calls.
Does it send transactions? No. It never signs or broadcasts anything.
What if CoinGecko is down? Balances still show; prices show as n/a and the last cached price is reused where available.
Why is a token missing? Either its balance is zero, or it isn't in src/tokens.js yet — add it there (address + decimals + CoinGecko id).
See CONTRIBUTING.md. PRs welcome — especially new chains, tokens, and tests.
MIT — see LICENSE.
git clone https://github.com/noone52/chainfolio.git
cd chainfolio
cp config/wallets.example.json config/wallets.json
# 把 config/wallets.json 里的地址换成你自己的公开钱包地址
npm start支持以太坊、BNB Chain、Base、Arbitrum、Optimism、Polygon 六条链,看原生币 + 主流 ERC-20 余额和美元总价,还能跑本地看板(node src/cli.js serve,打开 http://localhost:3000)。
