# π° Flask Expense Tracker
An interactive and secure expense tracking web app built with **Flask**, **Pandas**, **Matplotlib**, and **JavaScript**. It lets users log their daily expenses, visualize spending trends, manage savings goals, and view insightful dashboards.
---
## β¨ Features:
- π Encrypted account credentials and budgets
- π§Ύ Daily expense logging by category
- π Dashboard with:
- Pie chart (category distribution)
- Line graph (spending trends)
- Bar chart (budget % per day)
- π¬ Insight messages to guide your saving behavior
- π Automatically generated expense tables
- βοΈ Change income or saving goal from settings
- π Data stored in `Expenses.csv` and `Classified.csv`
---
## π Tech Stack:
- **Backend:** Python(Flask, Pandas)
- **Frontend:** HTML, CSS, JavaScript
- **Visualization:** Matplotlib
- **Encryption:** Self-made `simple_encrypter` module
---
## πΈDashboard preview:
| Chart | Description |
| -------------------------------------- | -------------------------- |
|  | Expense by category |
|  | Daily spending trend |
|  | Daily spending % of budget |
---
## πΉ Demo link
Try the app using this link: [Expense Tracker](https://web-expense-tracker-production.up.railway.app/)
---
## πGuide
1. open the demo link
2. click `sign up`
3. add your email password income and saving goal and click sign up
4. add your expenses by clicking on `add data` (do this daily)
5. click `generate dashboard` and see the insights and info about your spending patterns
6. if you want to change the entered income or saving goal, click on the last button and change them.
---
## π Running it locally
if you want to use the app but you are worried about the security of the site, here is how to run it locally!
### 1. Clone the Repo
```bash
git clone https://github.com/your-username/flask-expense-tracker.git
cd flask-expense-tracker
```
### 2. Install Requirements
```bash
pip install flask pandas matplotlib
```
### 3. Create Required Files
Ensure you have this folder structure:
πWeb-Expense-Tracker
β Classified.csv
β Expenses.csv
β main.py
β Procfile
β README.md
β requirements.txt
β simple_encrypter.py
β
ββββstatic
β β categories.js
β β change.js
β β home.js
β β login.css
β β login.js
β β logo.png
β β options.js
β β signup.js
β β
β ββββcharts
β pie.png
β plot.png
β trend.png
β
ββββtemplates
categories.html
change.html
error.html
home.html
login.html
options.html
signup.html
template.html
### 4. Run the App
```bash
python main.py
```
Then visit:
π http://localhost:5000
---
## π About `simple_encrypter`
Handles encryption and decryption of passwords and income using symmetric encryption.
If you are intrested, I have a repo only for it here:
simple-encrypter
---
## π Credits
Developed by Kevin Ehab