Project 06Private project

Property Management App

A private property management app for a family owned rental portfolio, covering records, leases, rent, insurance, taxes, maintenance and investor reporting.

Who uses it

A handful of family members who own and run the portfolio, signing in with approved Google accounts plus a second factor. Tenants never log in, and there is no public sign up.

Why it was built

Property records, leases, insurance renewals, tax deadlines and rent were scattered across documents, and missing one of those dates costs real money. I built one place that holds every record and works out the deadlines on its own instead of relying on someone to remember them.

What it does

Each property has a hub with tabs for overview, valuation, tax, insurance, leases, money, maintenance, documents and photos. It tracks leases and tenants with a running ledger, delinquency aging, late fees and expenses on tax schedule categories, plus depreciation schedules, a per property tax schedule export and a 1099 vendor report. The insurance module stores each policy's coverage in detail and derives alerts: renewal at 45 days, wind and hail deductible in dollars, underinsurance below 80 percent of replacement cost, vacancy clause risk and missing flood cover in a flood zone. A deadline feed and dashboard pull every date into one place, daily and weekly emails go out, and an investor reports section covers rent roll, cash flow, monthly profit, KPIs and a monthly close.

What it serves

It replaces scattered files and memory with one system that knows every property, policy, lease and deadline and tells the family before something is due. Success is no missed renewal, deposit return or tax deadline, and year end tax and investor numbers that come straight out of the app.

Under the hood

Next.js 15 App Router with TypeScript, Tailwind CSS 4 and shadcn style Radix components, on Supabase Postgres, Auth and Storage, with Drizzle ORM and 25 SQL migrations. All data access goes through server components and route handlers, Zod validates every input, and every mutation writes to an audit log. Deadline logic lives in pure TypeScript modules with Vitest coverage, and one collector feeds an alerts table that Vercel Cron upserts daily before Resend sends the emails. Upstash Redis rate limits every route handler, strict security headers and CSP are set in the Next config, and a weekly cron exports every table to CSV in a private backup bucket.

Flow

  1. Record a policy or lease
  2. Derive the deadline
  3. Upsert an alert
  4. Email the family
  5. Link back to the record

Built with

  • Next.js 15
  • TypeScript
  • Supabase Postgres
  • Supabase Auth
  • Drizzle ORM
  • Zod
  • Tailwind CSS 4
  • Radix UI
  • Resend
  • Upstash Redis
  • Vitest
  • Vercel Cron

How I built it

  1. I wrote a full spec first: the schema for nine modules, the security rules, the alert formulas and a nine phase build order, with the rule that each phase is built, run and checked before the next begins.
  2. Phase 1 laid the security foundation before any feature: Google sign in, an allowlist enforced by a before user created auth hook, deny by default middleware, row level security on every table, audit logging and a document vault behind private buckets.
  3. I then built leases and tenants, the rent ledger and expenses, insurance with derived alerts, valuations and tax, depreciation and tax reports, and maintenance, each with a manual test checklist and unit tests for the calculations.
  4. I wrote an importer that pulls a property record from free public sources (a geocoder, a flood zone map layer and county appraisal open data) and backfills several years of appraisal history, leaving anything not public for a person to fill in.
  5. Phase 8 and 9 added the alerts table, cron jobs, email digests, the CSV backup, rate limiting and headers, and I then required a second factor at the database level.
  6. Later I added investor reporting in five phases (inputs and shared report rules, the reports tab, insurance renewals, cash flow and rent roll detail, monthly close), plus scheduled report emails.

Key decisions

  • I enforced the allowlist twice: a Supabase auth hook refuses to create a user whose email is not approved, and middleware rechecks the allowlist on every request, so an unknown Google account never gets a session.
  • I required two factor authentication with restrictive RLS policies that demand an aal2 token on every data table, because a middleware only check would leave the REST endpoint open to a stolen cookie.
  • Money is summed in whole cents internally, because floating point addition leaves a tenant a fraction of a cent delinquent forever.
  • Deadline and finance calculations are pure functions with unit tests, and depreciation is checked against the IRS mid month convention table for all twelve months, because those numbers are the point of the app.
  • Alerts are upserted on a stable key from one collector, so a daily cron can run repeatedly without duplicates and each urgent email goes out once.
  • If rate limiting credentials are missing the limiter is disabled rather than failing closed, because a missing environment variable should never lock the family out of their own records.
The dashboard, shown with sample data
The dashboard, shown with sample data