Skip to main content

Daftarche

tests PyPI Python License

Daftarche (دفترچه, "little account book") is a desktop app for personal bookkeeping. It imports bank statements in QFX/OFX format, sorts every transaction into income, expense or transfer with categories, sub-categories and tags, matches transfers between your own accounts, and shows where the money went: a dashboard, monthly charts, account balances over time and a searchable transaction table that exports to Excel.

Everything stays on your computer, in one SQLite file. Statements have been tested with CIBC's QFX downloads; other banks' QFX/OFX files use the same format.

Daftarche dashboard: account balances, income and expense per month, expenses by category

Daftarche in use: the four tabs, Groceries in the charts, and a switch to the light theme

The screenshots show invented data (tools/make_demo_db.py).

Installation

Python 3.10 or newer. With pipx (its own environment, recommended):

pipx install daftarche

or with pip, in an environment of your choice:

pip install daftarche

To start it with a double-click, run once:

daftarche install-app

This adds Daftarche to your Applications folder (macOS), the Start menu (Windows) or the applications menu (Linux), with its own icon. It starts the daftarche of the Python you ran the command with, and keeps working after updates.

To update, use Help → Check for Updates… (⌘U) in the app (it also checks quietly at start-up) or daftarche update in a terminal.

For development, install from a clone: git clone https://github.com/vahid-anari/daftarche.git, then pip install -e ".[dev]" in the folder; such a copy is updated with git pull.

Use

daftarche                     open the app
daftarche update              update from PyPI (asks first; --check only looks)
daftarche install-app         add the app to Applications / Start menu (--remove to undo)
daftarche --version

File → Import Statement… (⌘I, or drag the file onto the window) reads a QFX statement downloaded from your bank's website; the account is recognised from the file, transactions already imported are skipped, and saved rules fill in the merchant and category. Edit what is left in the preview, then Import New; the new rows then show in Transactions, and those still without a category wait in To review (⇧⌘R). Match Transfers in the Transactions tab pairs the two sides of a transfer between your accounts. Edit → Manage… (⇧⌘M) edits the types, accounts, categories and tags; Edit → Settings… (⌘,) changes the font, colours and theme, and View → Appearance switches between Same as System, Light and Dark. View → To Review (⇧⌘R) and View → Unmatched Transfers… (⇧⌘U) show what is still left to sort, all time; double-click a line to see those transactions.

Transactions tab: filters by date, type, account, category and tags, and the transaction table with totals

Charts shows each month by category (lines or bars); hover a category to see its sub-categories, click to keep them.

Charts tab: monthly expenses by category as stacked bars, with the sub-categories of Groceries

Accounts shows each account's balance (or income, expense, transfers) month by month.

Accounts tab: balance of each account by month, as a chart and a table

On the phone

Daftarche on the phone (Android) shows the same four tabs and your loans, read-only. Your Mac keeps it up to date through your own Google Drive, locked with a key only the phone has: Settings › Phone › Connect a Phone…, and scan the code with the phone's camera. Install it from the newest Phone release on GitHub; more in mobile/README.md.

Phone: total balance, accounts, this month's income and expense, and the expense donut Phone: monthly expense by category as stacked bars Phone: one transaction opened, with its date, account, category and merchant

User Guide

Help → User Guide (⌘?) opens the guide in the app: getting started, importing statements, sorting, the four tabs, transfers, loans and splits, settings, backups, and the shortcuts. Its sources are in docs/ (user_guide.tex with its own style, guide.sty); sh tools/build_docs.sh builds it with XeLaTeX into src/daftarche/data/user_guide.pdf.

Your data

Nothing personal is stored in the program folder or in this repository. The app keeps its files in one folder:

~/Library/Application Support/Daftarche/      (macOS)
    daftarche.db                     all transactions, accounts, categories
    config.json                      theme and view settings
    backups/daftarche-last.db        written at every start
    backups/daftarche-YYYY-MM.db     first start of each month; the last 12 are kept

On Windows the folder is %APPDATA%\Daftarche, on Linux ~/.local/share/daftarche. Set DAFTARCHE_HOME to use another folder, for example a test copy. File → Back Up Database… and Restore Backup… save and load a copy of the database by hand; File → Open Database… shows a backup (through a copy) without changing anything. The monthly snapshots sit on the same disk as the database; Settings → Extra backup folder also copies them to a folder of your choice (iCloud Drive, an external disk), and Time Machine covers the data folder too. Help → Show Data Folder opens it.

Development

pip install -e ".[dev]"
pytest

The tests use only invented data (tests/data/sample.qfx) and a temporary data folder. python tools/make_icon.py redraws the icon and the splash image. python tools/make_demo_db.py makes a demo database with a year of invented transactions in its own folder (default ~/Desktop/daftarche-demo), for screenshots or trying the app without your own data: DAFTARCHE_HOME=~/Desktop/daftarche-demo daftarche. python tools/figures.py retakes the pictures and the animation in docs/figures/ from a new demo database (--list for the names); on macOS with the title bar and shadow, which needs Screen Recording permission for the terminal.

Two one-off tools fill in notes for past online purchases: python tools/export_shop_charges.py writes the Amazon and AliExpress transactions (only those, and only the columns needed) to shop_charges.csv; python tools/import_notes.py notes.csv shows the notes and categories a filled-in copy would write, and --apply writes them after backing up the database. python tools/list_categories.py prints every category and sub-category with its number of transactions and rules (--totals adds amounts). python tools/remap_categories.py export writes one line per sub-category to mapping.csv, to say where each goes (merchant, new category, money back); apply mapping.csv shows the moves and --apply makes them after backing up the database. Pushing a tag vX.Y.Z publishes a GitHub Release with that version's section of CHANGELOG.md; python -m build && twine upload dist/* puts it on PyPI.

Support

Daftarche is free, and I work on it in my spare time. If it's useful to you, you can buy me a coffee ☕

License

MIT License. See LICENSE.

Author

Vahid Anari · GitHub · LinkedIn

Built with sciwidgets, the widget package shared with the author's scientific apps.

Metadata

Release files for daftarche 0.29.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for daftarche 0.29.1
File Size Uploaded Provenance
daftarche-0.29.1.tar.gz 2.6 MB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for daftarche 0.29.1
File Interpreter ABI Platform
daftarche-0.29.1-py3-none-any.whl Python 3 none any Details

Total release size: 5.2 MB

Release files / daftarche-0.29.1.tar.gz

Download URL daftarche-0.29.1.tar.gz
Size 2.6 MB
Tags Source
SHA-256 checksum
How to use checksums
2ffeb82d9283938976b49f885883abbe21501b0a15d628c2f136509d6b8285c0
BLAKE2b-256 checksum
How to use checksums
876ce968580e874458e85beb8e3636da2e415782bcdaaee010362eb9f7de9c99
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / daftarche-0.29.1-py3-none-any.whl

Download URL daftarche-0.29.1-py3-none-any.whl
Size 2.6 MB
Tags Python 3
SHA-256 checksum
How to use checksums
2cfcc6aef9c302db90912831411a2ddb518f3a86bfd19ee83edb7c56965c545f
BLAKE2b-256 checksum
How to use checksums
455002a1d3755070fc89fcea16c44014ad0b48f205083729c2560af94e751248
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Security for daftarche 0.29.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.29.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page