KharchaTrack is a full stack web-based expense tracking application built to help users manage their daily expenses in a simple and effective way.
Dashboard
analytics
accounts
- 🔐 User authentication (Signup & Login)
- ➕ Add new expenses
- 📜 View all expenses in a list
- ❌ Delete specific expenses
- 📊 Visualize expense summaries using Chart.js
- 🌱 Minimal UI, built for simplicity and learning
Frontend
- HTML
- CSS
- JavaScript
Backend
- Node.js
- Express.js
Database
- SQLite
Other Tools
bcryptfor secure password hashingjsonwebtokenfor session handlingdotenvfor managing environment variablesChart.jsfor data visualization
KharchaTrack/
└── KharchaTrack v0.1/
├── .env
├── .gitignore
├── config.js
├── database.js
├── package.json
├── package-lock.json
├── server.js
├── db/
│ └── mydb.db
├── middleware/
│ └── auth.js
├── public/
│ ├── index.html
│ ├── login.html
│ ├── signup.html
│ ├── style.css
│ └── script.js
└── routes/
├── auth.js
└── expenses.js
- Node.js installed (version 16+ recommended)
- Git installed
git clone https://github.com/anonyash/KharchaTrack.git
cd "KharchaTrack/KharchaTrack v0.1"
npm installCreate a .env file in the root with the following:
PORT=3000
JWT_SECRET=your_jwt_secret_hereRunning the App For development (auto-restarts on changes):
npm run devstartFor production:
npm startThe app will be available at http://localhost:3000 (or the port defined in .env).
-
Console Logs for Debugging
This project contains multipleconsole.log()statements in both backend and frontend files.
These were intentionally added to help trace app behavior during development.
You can remove them or replace them with a logging library likewinstonormorganfor cleaner output in production. -
Code Organization
The project is structured simply for clarity:server.js,database.js, andconfig.jsare at the root.- Routes are in the
/routesfolder. - Middleware lives in
/middleware. - Static files are in
/public.
-
Security Notes
While authentication is implemented usingbcryptandjsonwebtoken, additional improvements could be made:- Input validation (e.g., using
express-validator) - Rate limiting to prevent brute-force attacks
- CSRF protection and secure cookie handling
- HTTPS setup for production environments
- Input validation (e.g., using
-
Database Reset
KharchaTrack uses SQLite.
(you can download a DB browser with UI to view the database)To reset your data, just delete the
mydb.dbfile located in the/dbfolder.
The database will be recreated automatically with the basic structure on next server start.
- Expense categories and filters
- Monthly/weekly summaries
- User profile settings
- Responsive/mobile-friendly UI
- Dark mode
This project is licensed under the ISC License.
This project was built as a personal initiative to learn full stack development
by building something meaningful.
Feedback and contributions are welcome!
Made with ☕👩🏻💻 by Yashvardhan Rajpurohit

