Building a Personal Finance PWA on Cloudflare Workers

Dark technical illustration of ledger bars and edge-network sync nodes representing a personal finance PWA on Cloudflare Workers

One of the engineering projects I’m most proud of is FinRec — a full-featured personal finance progressive web app running entirely on Cloudflare Workers with D1 as the database layer. No traditional server. No monthly hosting bill beyond Cloudflare’s generous free tier. Just edge-deployed JavaScript serving a complete financial dashboard.

The Architecture

FinRec is built as a single Cloudflare Worker that serves both the PWA frontend and the API backend. The frontend is a service-worker-cached progressive web app with offline support, installable on any device. The backend routes API calls to a D1 SQLite database that stores net-worth snapshots, a normalized ledger, a document ingestion queue, and health-monitoring data.

The key insight was treating the Worker as a full application server. A single fetch handler routes between static assets (/sw.js, /manifest.json), the login page, the main SPA shell, and a dozen API endpoints — all from one deployment artifact.

What It Does

The dashboard has four tabs: Overview (net worth tracking with daily snapshots, asset/liability breakdown, orchestrator health monitoring), Ledger (full transaction history with month/type/search filtering), Documents (an AI-powered document ingestion queue that classifies uploaded financial documents, extracts vendor/amount/date, and flags items needing review), and Advisor (a CFO-level financial briefing generator that produces weekly reports and saves them to Google Drive).

The Supporting Fleet

FinRec doesn’t operate alone. It’s the dashboard layer for a larger fleet of 60+ Cloudflare Workers that handle data ingestion, classification, and orchestration. These include OAuth 2.0 token capture workers, cron-triggered financial data sync pipelines, Gmail and Google Drive ingest workers, a transaction classifier/trainer, a document processor, ledger normalizer, and a meta-orchestrator that monitors the health of the entire system.

Why Cloudflare Workers

The edge deployment model means every API call resolves at the nearest Cloudflare data center. D1’s SQLite-on-the-edge gives me ACID transactions without managing a database server. R2 provides S3-compatible object storage for document uploads. And the whole thing costs effectively nothing to operate at personal scale.

For engineers evaluating where to host side projects and internal tools, I’d argue that Cloudflare Workers + D1 + R2 is the most underappreciated full-stack platform available today. The developer experience is excellent, the deployment model eliminates infrastructure management, and the performance characteristics are hard to beat.

This is one project in a larger portfolio. See the full list on my Projects page.

Comments

Leave a Reply

Discover more from Grounded Intelligences

Subscribe now to keep reading and get access to the full archive.

Continue reading