Bill-Generator v4.5.1 · MIT Download
Made for India · UPI ready · Local-first & self-hosted

Invoicing that lives on your counter,
not on someone else's server.

A free, MIT-licensed billing & accounting app built for Indian small businesses and solo freelancers — print shops, stationery counters, designers, tutors, tailors, consultants, repair workshops. UPI QR payments, GST-friendly invoices, rupee amounts in words, and per-period statements — all running on the machine sitting under your desk.

One-liner
$git clone https://github.com/dineshmiriyala/bill-generator-oss && cd bill-generator-oss && pip install -r requirements.txt && python app.py
Python 3.11+ SQLite bundled Default port 127.0.0.1:42069 License MIT
Built for Indian SMBs & freelancers Print & xerox shops Designers & photographers Tutors & coaching centres Consultants & CAs Tailors & boutiques Repair workshops Stationery counters Anyone tired of per-seat SaaS
Three-step invoicing

From client to printed invoice
in well under a minute.

The whole flow is intentionally short. Pick someone you already know, type or pick the items, hit print. Drafts, duplicates, and the “bill with dues” picker for repeat customers all live in the same screen.

Pick a customer

Search by phone, name, or company. Duplicate detection catches when the same person walks in under two spellings.

🔍   Ravi5 results
Ravi Kumar · Sai Traders98••• 12340
Ravi Tailors · MG Road98••• 51122
Ravi S · walk-in

Add line items

Type-ahead from inventory, or one-off entries for service work. Per-row tax, discounts, and notes. Save as a draft if the client is still deciding.

Logo design · 3 concepts1 × 5,000
Brochure design · A41 × 3,000
Brochure print · 200 copies200 × 8.00
Subtotal9,600.00

Preview & print

Browser-native print to paper or to PDF — no headless Chrome, no extra runtime. A UPI QR can be embedded so clients can pay before they leave the chat.

InvoiceINV-280526-00042
Total payable₹ 11,328.00
UPI QRembedded
OutputPaper · PDF · Share
What's in the box

A full back-office,
not a billing toy.

Customers, inventory, accounting, analytics, statements, backups, QR payments, optional cloud mirror. Every feature is opt-in and scoped to the one machine it runs on.

Customers & inventory, fully CRUD

Soft-delete with a recovery centre, duplicate detection on phone + company, and inline edit from anywhere. Nothing disappears the first time you click delete.

/view_customers · /view_inventory · /recover

Accounting workspace

Record payments and expenses, see per-customer dues at a glance, and print accounting statements for any date range — month, quarter, or financial year.

TXN-280526-000001 · per-period statements

Analytics

Sales by day, month, year. Top customers. Weekday breakdowns. Self-hosted — no Google, no Mixpanel.

Chart.js · local events only

Made for India, out of the box

UPI QR codes via segno, GST-friendly invoices, and amounts spelled out in Indian-numbering rupee words — “Four Thousand Three Hundred and Seven Only”. No add-ons, no setup.

UPI · GST · ₹-in-words

Automatic local backups

Timestamped SQLite snapshots in db/backups/, ten kept, older pruned. Optional mirror to any folder inside your home directory.

7-day staleness check at shutdown

Opt-in Supabase sync

Bring your own project to mirror data off-machine. HTTPS-only, RFC1918 blocked, disabled until you configure it.

supabase_upload.py

One-step desktop packaging

A single build_exe.bat emits BillGenerator_V4.5.1.exe for Windows. The same code runs as a normal Flask app anywhere Python does.

PyInstaller + pywebview

White-label without touching source

BG_APP_NAME, BG_INVOICE_PREFIX, BG_TXN_PREFIX env vars rebrand the window title, invoice IDs, and packaging metadata.

env vars · info.json
Why local-first

Your customer list is not
somebody else's product.

Most billing tools either ship your customer list to a vendor's cloud or charge per seat. This one runs entirely on the machine under the desk and only talks to the network when you configure it to.

 
Bill-Generator
Typical cloud SaaS
Where data lives
SQLite file on your machine
Vendor's database
Pricing
Free · MIT
Per-seat, per-month
Works offline
Yes — designed for it
Rarely fully functional
Cloud sync
Opt-in, bring your own Supabase
Mandatory
Customer data export
The SQLite file is the export
CSV, if you're on the right plan
Audit surface
Read the source, all 100% of it
Trust the SOC2 PDF
0
forever · no tiers · no seats

That, in full, is the pricing page.

A note on intent

Free, open source,
and staying that way.

There is no paid tier in development. No "Pro" features held behind a paywall. No SaaS version waiting in the wings to swallow the local one once enough shops come to depend on it. No telemetry being collected to monetise later. No investors to answer to.

  • No per-seat fees, ever
  • No "Pro" upgrade to unlock features
  • No cloud-only version coming later
  • No telemetry phoning home
  • No ads, sponsored items, upsells
  • No VC money with strings attached

The repository is MIT-licensed, the SQLite file is the export, and the binaries come from a build script you can read in an afternoon. The intent is simple: invoicing is plumbing, and Indian small businesses and freelancers deserve plumbing that doesn't extract ₹999 a month per seat. So here's some.

If it's useful to you, the only ask is that you tell another shop owner or freelancer about it. If you can ship a patch — even better.

Bill-Generator contributors MIT · No telemetry · No accounts
Under the hood

Boring on purpose.
Maintainable by design.

Nothing exotic — Flask, SQLAlchemy, SQLite, Jinja, Bootstrap, waitress, pywebview. The kind of stack you can still maintain a decade from now, with a tree shallow enough to read in an afternoon.

Backend
Flask 3.x + SQLAlchemy 2.x + Flask-Migrate, served by waitress.
Database
SQLite — single file in db/app.db, or the OS data dir in desktop mode.
Migrations
Alembic scripts under migrations/versions/, run on startup.
Frontend
Jinja templates with Bootstrap, Chart.js for analytics. No bundler, no Node.
PDFs
Browser print-to-PDF. No headless Chrome, no LaTeX runtime.
QR
segno generates UPI QR codes as base64 SVG.
Statements
openpyxl + reportlab for spreadsheet & PDF exports.
Desktop shell
pywebview renders the local Flask app in a native window.
Packaging
PyInstaller · one-step Windows build via build_exe.bat.
Tests
pytest, runs against a temp data dir — never touches your real info.json.
.
├── app.py                 # Flask routes, branding, backups, sync
├── api.py                 # JSON / UPI-QR endpoints
├── analytics.py           # Sales / customer aggregations
├── analytics_tracking.py  # Front-end event logging (local)
├── supabase_upload.py     # Optional cloud mirror
├── migration.py           # Startup schema migration
├── desktop_launcher.py    # pywebview entrypoint
├── build_exe.bat          # Windows one-step packaging
├── db/
│   ├── models.py          # SQLAlchemy models
│   ├── db_events.py       # ORM event hooks
│   └── info.example.json  # Settings template
├── migrations/         # Alembic versions
├── templates/          # Jinja (Bootstrap-based)
├── static/             # CSS / JS / SVG / fonts
└── tests/              # pytest suite
Configuration

Every knob is an
environment variable.

Branding and networking switches are prefixed BG_. Per-install business settings live in info.json and are editable in-app — no restart needed.

VariableDefaultWhat it does
BG_APP_NAME Bill-Generator Window title, logs, packaging metadata. Set this to white-label.
BG_INVOICE_PREFIX INV Invoice ID prefix — e.g. INV-280526-00042.
BG_TXN_PREFIX TXN Accounting transaction ID prefix.
BG_BIND_HOST 127.0.0.1 Set 0.0.0.0 to expose on the LAN — read the security note first.
BG_DESKTOP unset Set to 1 for the OS-specific data directory (set automatically by the desktop launcher).
BG_APP_VERSION baked in Override the version string at runtime.
SECRET_KEY auto-generated Flask session key. A random 32-byte key is generated and persisted on first launch if unset.
Quick start

Two paths.
Both end in printing.

Run as a normal Flask app anywhere Python runs, or grab the packaged .exe for Windows machines that have never seen a terminal.

From source · Linux / macOS / Windows ~2 min
# 1 — Clone & enter
git clone https://github.com/dineshmiriyala/bill-generator-oss
cd bill-generator-oss

# 2 — Create & activate venv
python -m venv .venv
source .venv/bin/activate         # Windows: .venv\Scripts\activate

# 3 — Install & run
pip install -r requirements.txt
python app.py

# Opens at http://127.0.0.1:42069
# First launch boots the onboarding wizard.
# To skip while exploring:
cp db/info.example.json db/info.json
Packaged .exe · Windows desktop ~5 min build
# From the repo root, on a Windows box
# with Python 3.11+ on PATH:

build_exe.bat

# Result:
dist\BillGenerator_V4.5.1.exe

# The script:
#   · creates a cached .build-venv
#   · installs deps + PyInstaller
#   · emits a single-file .exe
#   · re-runs reuse the venv

# Double-click the .exe — it opens
# inside a pywebview window, bound
# to 127.0.0.1 only.
API reference

A handful of endpoints.
That's the whole API.

All endpoints serve 127.0.0.1 by default with no authentication — the threat model assumes a single user on a single machine. See the security note below before changing the bind host.

GET /api/bill_items/<invoice_no> Customer + line items + totals for an invoice.
GET /api/generate_upi_qr Base64 SVG UPI QR. Params: upi_id (required), am, pn, cu.
GET /accounting/customer_summary/<customer_id> Invoiced / paid / outgoing / balance snapshot for one customer.
GET /accounting/amount_to_words Convert a numeric amount to Indian-numbering-system rupee words.
GET /api/statements Per-period statement summaries — date range or year / month.
GET /api/statements/invoices Paginated raw invoice export.
POST /analytics_event Records front-end analytics events locally. Never leaves the machine.
!

Single-user, local-only — by design.

The app ships with no authentication, partial CSRF protection (bill forms only), and no encryption at rest. Defaults bind to loopback so only your machine can reach it. If you change the bind host, you're stepping outside the supported threat model — read SECURITY.md first and consider a fork with Flask-Login + global CSRF on top.

Roadmap & contributing

Pull requests welcome.
Especially the unglamorous ones.

Areas where help is especially appreciated. See CONTRIBUTING.md for setup, test, and style guidelines — the test suite runs against a temp data dir, so you can hack without fear.

Shipped · v4.5.1
  • Three-step invoicing with drafts, duplicates, & "bill with dues" picker.
  • Customers, inventory, accounting with soft-delete & recovery.
  • Analytics — sales, top customers, weekday breakdowns.
  • UPI QR generator via segno.
  • Automatic local backups + optional folder mirror.
  • Opt-in Supabase sync with HTTPS + RFC1918 checks.
  • One-step Windows .exe via PyInstaller.
  • Random SECRET_KEY generated & persisted on first launch.
In progress
  • Global CSRF protection across all state-changing routes (Flask-WTF).
  • Pluggable currency formatting — number-words beyond the Indian numbering system.
  • Brand asset replacement — drop in your own logo without source edits.
  • Onboarding polish — smoother first-launch wizard.
Get started

Bills, ledgers, and UPI QR codes — all under your roof.

Clone the repo, run one command, print a GST-friendly invoice in the next ten minutes. Free forever, fork at will, client list never leaves your machine.