A modern web application to track personal expenses with budget monitoring and analytics.
app.py- Flask web applicationmain.py- Command-line version (legacy)expenses.csv- CSV file to store expense datatemplates/- HTML templates for the web interfacegenerate_data.py- Script to generate sample expense data
-
Install Dependencies:
pip install -r requirements.txt
Or manually:
pip install flask pandas matplotlib
-
Run the Web Application:
python app.py
-
Open your browser and go to:
http://127.0.0.1:5000
- Add expenses with date, category, and amount
- View all expenses in a searchable table
- Real-time budget limit checking
- Set daily budget limits for each category
- Automatic alerts when limits are exceeded
- Visual progress bars showing budget usage
- Interactive charts and graphs
- Daily expense reports
- Category-wise spending analysis
- Monthly spending trends
- Daily budget limit warnings
- Over-budget notifications
- Spending insights and recommendations
The app includes these predefined categories with suggested daily budgets:
- Food: ₹500/day
- Transportation: ₹800/day
- Entertainment: ₹1000/day
- Shopping: ₹1500/day
- Bills: ₹3000/day
- Healthcare: ₹1500/day
- Education: ₹1200/day
- Click "Add Expense" from the sidebar
- Select date, category, and enter amount
- The app will automatically check budget limits
- Use "Daily Report" to see expenses for a specific date
- Check "Analytics" for charts and insights
- View all expenses in "View Expenses"
- Go to "Settings" to adjust daily budget limits
- Get real-time feedback on budget usage
To generate sample expense data for testing:
python generate_data.pyThis creates 3,192 random expenses spanning from Jan 1, 2025 to Apr 1, 2026.
- Backend: Python Flask
- Frontend: HTML5, CSS3, Bootstrap 5, JavaScript
- Data: Pandas for data manipulation
- Charts: Matplotlib for visualizations
- Storage: CSV file (easily replaceable with database)
The application uses:
- Flask for web framework
- Bootstrap 5 for responsive UI
- Font Awesome for icons
- Pandas for data processing
- Matplotlib for chart generation