A lightweight, full-featured Inventory Management System built with Flask and SQLite. Track stock levels, get low-stock alerts, analyse inventory value by category, and export reports — all from a clean web UI.
🔗 Live Demo: neelkanth-ims.onrender.com
| Feature | Description |
|---|---|
| 📦 Full CRUD | Add, edit, and delete inventory items |
| 📊 Dashboard Stats | Total items, low-stock count, out-of-stock count, total inventory value |
| 🔍 Search & Filter | Filter by name, supplier, notes, or category; sort by any column |
| 📉 Low Stock Alerts | Browser notifications when items fall below threshold |
| 📈 Analytics | Category breakdown, top-value items, stock health, 14-day activity trend |
| 📤 CSV Export | Download full inventory as a formatted CSV |
| 📊 Excel Export | Multi-sheet XLSX report — Inventory, By Category, Low Stock |
| 🪵 Activity Log | Tracks every add / update / delete with timestamps |
| 🚀 Boot Stream | SSE-powered animated startup sequence |
NeelKanth-IMS/
├── app.py # Flask application (routes, DB logic, exports)
├── templates/
│ └── index.html # Single-page frontend (HTML + JS)
├── requirements.txt # Python dependencies
├── render.yaml # Render deployment config
├── Procfile # Gunicorn start command
├── runtime.txt # Python version pin
└── .gitignore
- Backend: Python 3.11, Flask 3.x
- Database: SQLite (via Python's built-in
sqlite3) - Frontend: Vanilla HTML / CSS / JavaScript (no frameworks)
- Export:
openpyxlfor Excel,csvstdlib for CSV - Server: Gunicorn (production), Flask dev server (local)
- Streaming: Server-Sent Events (SSE) for boot sequence
git clone https://github.com/TRINEXOR/NeelKanth-IMS.git
cd NeelKanth-IMSpython -m venv venv
# Windows
venv\Scripts\activate
# macOS / Linux
source venv/bin/activatepip install -r requirements.txtpython app.pyOpen your browser at http://127.0.0.1:5000
The database (
inventory.db) is created automatically on first run and seeded with 10 sample items.
The repo includes a render.yaml — just connect it to Render and it deploys automatically.
startCommand: gunicorn app:app --bind 0.0.0.0:$PORT --workers 2 --timeout 120
⚠️ Note: Render's free tier uses an ephemeral filesystem. The SQLite database resets on each redeploy or restart. For persistent data, consider adding a Render Persistent Disk or migrating to PostgreSQL.
- Upload files via the Files tab or
git clonein the Bash console - Create a virtual environment and
pip install -r requirements.txt - Configure a new Web App pointing to
app.py - SQLite data persists between restarts on PythonAnywhere's free tier ✅
- Push to GitHub → connect repo on railway.app
- Set start command:
gunicorn app:app --bind 0.0.0.0:$PORT - Deploy — Railway provides $5 free credits monthly
| Method | Endpoint | Description |
|---|---|---|
GET |
/api/items |
List all items (supports search, category, low_only, sort, order) |
POST |
/api/items |
Create a new item |
PUT |
/api/items/<id> |
Update an item |
DELETE |
/api/items/<id> |
Delete an item |
GET |
/api/stats |
Dashboard summary stats |
GET |
/api/categories |
List all categories |
GET |
/api/analytics |
Full analytics payload |
GET |
/api/log |
Last 50 activity log entries |
GET |
/api/export/csv |
Download CSV report |
GET |
/api/export/excel |
Download multi-sheet XLSX report |
GET |
/api/alerts/low-stock |
Low-stock items for notifications |
POST |
/api/alerts/config |
Enable / disable browser notifications |
POST |
/api/alerts/ack |
Acknowledge notification |
GET |
/api/boot-stream |
SSE boot sequence stream |
| Column | Type | Description |
|---|---|---|
id |
INTEGER PK | Auto-increment |
name |
TEXT | Item name |
category |
TEXT | Category (default: General) |
quantity |
INTEGER | Current stock quantity |
unit |
TEXT | Unit of measure (kg, pcs, L, …) |
low_stock |
INTEGER | Low-stock threshold |
price |
REAL | Unit price (₹) |
supplier |
TEXT | Supplier name (optional) |
notes |
TEXT | Free-text notes (optional) |
updated_at |
TEXT | ISO 8601 timestamp of last update |
Tracks every item add, update, and delete with item_id, item_name, action, details, and timestamp.
Single-row config for browser notification state (enabled, last_notified).
On first run, if the database is empty, 10 sample items are automatically inserted across categories: Grains, Oils, Canned Goods, Legumes, Condiments, Baby, and Hygiene.
This project is open source. Feel free to fork and adapt for your own use.
Built with ❤️ by TRINEXOR