Inspiration
This project came from watching my own relatives struggle with money. Every month, no matter how much they earned, they'd end up empty-handed by the last week — no clear plan, no savings, just paycheck to paycheck. When I asked them why, the answer was always the same: they never had a simple system to follow.
I decided to build something that could actually help — not just for them, but for me too. A tool that takes a salary, applies a proven budgeting rule, and shows exactly where the money should go, in plain numbers they could actually use.
What it does
Expenditure Calculator turns a salary into a clear, actionable budget:
- Choose from 8 budgeting rules — from the simple 80/20 split to Zero-Based Budgeting and the aggressive 60/30/10 rule for FIRE-minded savers.
- Get a visual breakdown of where every rupee (or dollar, pound, euro...) should go.
- Set a savings goal and see a realistic projection of how many months it'll take to reach it.
- View an annual savings projection based on your chosen rule.
- Receive personalized recommendations based on income level, currency, and rule choice.
- Support for 7 currencies, including PKR and INR with inflation-aware advice.
- Keep a private calculation history, tied securely to your session.
How we built it
- Backend: Python and Flask, with all budget math and validation handled server-side.
- Database: SQLite for lightweight, thread-safe storage of calculation history.
- Frontend: HTML templates rendered through Flask's Jinja2 engine.
- Security, built in from the start:
- CSRF protection on every form submission, with token rotation after destructive actions.
- Dual-layer rate limiting (session-based and IP-based) to prevent abuse.
- Hardened session cookies (
HttpOnly,SameSite, secure in production). - Full security headers — CSP, X-Frame-Options, Referrer-Policy, Permissions-Policy.
- IP addresses hashed before logging, never stored raw.
- Strict input validation on salary, savings goals, and currency to prevent bad or malicious data.
- Only raw inputs are stored in history — calculated outputs are never persisted, and are recomputed fresh from trusted data every time.
Challenges we ran into
Balancing simplicity for the user with rigor under the hood — the interface needed to feel like a two-minute tool, even though a lot of validation and security logic runs behind every click.
Designing rate limiting that stops abuse without punishing normal users who just want to try a few different rules back-to-back.
Handling currency conversion and formatting cleanly across very different number scales (PKR salaries in the hundreds of thousands vs. USD/GBP in the thousands).
Making sure the savings goal projection felt realistic instead of overly optimistic — we deliberately reserve only half of the "Savings" allocation toward a specific goal, since real budgets rarely dedicate 100% of savings to one thing.
Accomplishments that we're proud of
- Built a tool that's genuinely usable by someone with zero financial background — no jargon, just numbers and clear categories
- Implemented production-grade security practices (CSRF, rate limiting, CSP, hashed logging) in a project that started as a simple personal favor for family
- Covered 8 distinct, real-world budgeting philosophies instead of hardcoding just one "correct" way to budget
- Kept the history feature privacy-conscious by storing only raw inputs and reconstructing everything else from trusted server-side data
What we learned
- How much of a difference a structured budgeting rule makes for people who've never had one — even a basic 50/30/20 split gave immediate clarity to test users
- The importance of designing security from day one, not bolting it on later — things like CSRF tokens and rate limiting are far easier to get right when they're part of the original architecture
- That personal finance tools succeed or fail on trust — people need to feel their data is safe and their numbers are accurate before they'll rely on any recommendation
What's next for Expenditure Calculator
- Multi-goal tracking — support several savings goals running in parallel, not just one at a time
- Expense tracking over time, not just single-point calculations, so users can see trends month over month
- Exportable reports (PDF/CSV) so people can share their budget with family or a financial advisor
- Localized recommendations for more countries and currencies beyond the current set
- Account-based sync so history follows a user across devices, not just a browser session
- Turning this from a personal project into something my own relatives — and hopefully others in similar situations — actually use every month..
Log in or sign up for Devpost to join the conversation.