Stop digging through email attachments. Keep your family's policy documents safe, organized, and fully under your control.
A modern, containerized application to track insurance policies (Buildings, Car, Contents, Life, Medical, and Pet) and household assets (Vehicles and Pets) across multiple households. Built for self-hosters who value privacy and data ownership.
- Multi-Household Support: Create, switch, rename, and delete households (with safeguards for the last household) from a single instance.
- Asset Inventory: Manage Vehicles and Pets, link them directly to Car and Pet policies, add them inline from policy forms, or save free-text entries to Inventory when creating a policy.
- Type-Specific Policies: Tailored forms and detail views for Buildings, Car, Contents, Life, Medical, and Pet insurance, separated into Active (including perpetual) and Expired sections.
- Document Storage: Upload, replace, and preview policy PDFs directly in the browser.
- Localization & Formatting: Choose display currency (
GBP,EUR,USD,AUD,CAD) and browser-default or custom date/number locale formatting (en-GB,en-US,en-AU,en-CA,ISO 8601,de-DE,fr-FR). - System / Light / Dark Mode: Responsive UI following your OS preference by default, with navbar quick toggle and 3-state selector in Settings.
- Single-Container Deployment: Multi-stage Docker image serving the built Vue SPA, API, and uploads from FastAPI/Uvicorn on a single port.
Policy details
Creating household assets
Create new Car insurance policy
More screenshots are available in docs/img
This is the recommended way to run the application.
-
Create or use
docker-compose.ymlBuild locally from this repository (default in
docker-compose.yml):services: policynest: build: . container_name: policynest ports: - 8000:8000 volumes: - ./data:/data restart: unless-stopped
Or replace
build: .withimage: splinterhead27/policynest:latestto run a published image. -
Start the stack
docker compose up -d --build
(Or run
just run/just stopvia the rootJustfile.) -
Access the App
- Frontend & API:
http://localhost:8000 - Backend API Docs (Swagger UI):
http://localhost:8000/docs
- Frontend & API:
-
First Run: You will be prompted to create your first Household (e.g., The Smith Residence) to initialize your workspace.
- Assets Layer: Attach Car and Pet policies to Vehicle and Pet inventory assets.
- Authentication: Add user login support.
- Database Integration: Switch from SQLite to PostgreSQL for larger deployments.
- Renewal Alerts: Email notifications when a policy is ending.
If you want to contribute or run the app locally without Docker:
- Requirements: Python
>=3.14(Docker usespython:3.15-slim), Poetry, Node.js^20.19.0 || ^22.13.0 || >=24(Docker usesnode:26-alpine), and optionallyjust.
just install # Installs backend Poetry deps and frontend npm deps
just fmt # Runs isort + black on backend and Prettier on frontendcd frontend
npm install
npm run build # Builds dist/ served by FastAPI on :8000
npm run lint # Runs ESLint (use `npx eslint . --max-warnings 0` for strict check)
npm run format # Formats src/ with Prettier
npm run dev # Starts standalone Vite dev server (no /api proxy configured)POLICYNEST_DATA_DIR defaults to /data, so point it to ../data when running locally outside Docker:
cd backend
poetry install --no-root
POLICYNEST_DATA_DIR=../data poetry run alembic upgrade head
POLICYNEST_DATA_DIR=../data poetry run uvicorn app.main:app --reloadWith frontend/dist built and Uvicorn running, open http://localhost:8000.
PolicyNest runs as a single monolith container built via multi-stage Dockerfile:
- Frontend: Vue 3.5, Vuetify 4.3, Vue Router 5, Axios, built with Vite 8 and served from
frontend/distby FastAPI (/SPA routes,/assets/*, and cached static assets such as/favicon.ico). - Backend: FastAPI 0.165, Pydantic 2.14, SQLAlchemy 2.1 ORM, Alembic 1.20 migrations, running on Uvicorn 0.54 (Python 3.15 in Docker).
- Database: Local SQLite (
policynest.dbinsidePOLICYNEST_DATA_DIR, defaulting to/data). - Storage: Uploaded PDF policy documents stored under
${POLICYNEST_DATA_DIR}/uploadsand served at/data/uploads.
PolicyNest/
├── backend/
│ ├── alembic/ # Alembic migration environment & versions
│ ├── app/
│ │ ├── routes/ # API routers (asset, household, policy, system)
│ │ ├── database.py # SQLite engine & POLICYNEST_DATA_DIR setup
│ │ ├── main.py # FastAPI app, API router, uploads & SPA serving
│ │ ├── models.py # SQLAlchemy ORM models
│ │ ├── schemas.py # Pydantic request/response schemas
│ │ └── uploads.py # PDF upload storage helpers
│ ├── alembic.ini
│ ├── Justfile
│ └── pyproject.toml # Poetry dependency management
├── frontend/
│ ├── public/ # Static assets (favicon.ico)
│ ├── src/
│ │ ├── components/ # Shared dialogs, nav shell, policy forms & details
│ │ ├── router/ # Vue Router configuration
│ │ ├── services/ # Axios API client (/api)
│ │ ├── utils/ # Policy/Asset type metadata & locale formatters
│ │ └── views/ # Page views (Policies, Inventory, Settings)
│ ├── index.html
│ ├── Justfile
│ ├── package.json
│ └── vite.config.js
├── docs/img/ # README screenshots
├── docker-compose.yml
├── docker-entrypoint.sh # Runs `alembic upgrade head` then starts Uvicorn
├── Dockerfile # Multi-stage Node 26 + Python 3.15 build
└── Justfile # Root install, format, and Docker compose tasks
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.



