A simple command-line expense tracker written in Python. It allows you to add expenses, view them, filter by category, calculate totals, and save/load data from CSV files. Extra features include monthly summaries and category-based reports, all presented in a basic table format.
- Add expense (amount, category, description, date)
- View all expenses in a table
- View total expenses
- Filter expenses by category
- Save expenses to a CSV file
- Load expenses from a CSV file
- Monthly summary of spending
- Total per category report
- Clean CLI menu system
Run the script using Python 3:
python expense_tracker.pyFollow the on-screen menu to interact with the program. Date format is YYYY-MM-DD, and pressing enter when prompted for a date will use today's date.
Expense Tracker
1. Add Expense
2. View Expenses
3. View Total
4. Filter by Category
5. Save to CSV
6. Load from CSV
7. Exit
8. Monthly Summary
9. Expense per Category
Choose an option: 1
Amount: 23.50
Category: Food
Description: Lunch
Date (YYYY-MM-DD) [today]: 2026-02-18
Expense added.
Expense Tracker
1. Add Expense
2. View Expenses
3. View Total
4. Filter by Category
5. Save to CSV
6. Load from CSV
7. Exit
8. Monthly Summary
9. Expense per Category
Choose an option: 2
Date Amount Category Description
------------------------------------------------------------
2026-02-18 23.50 Food Lunch
Expense Tracker
... etc.
- The CSV save/load uses a header row
amount,category,description,date. - Invalid inputs are handled gracefully with messages. You can exit at any time via the menu or
Ctrl+C.
Oluwafemi Bamidele