Stock Portfolio Tracker is a portfolio tracking web tool designed for NEPSE that provides summary of the overall gains and loss using Chart.js library after uploading the Meroshare transactions csv file. Stock Portfoilo Tracker gets live stock day prices data from NepaliPaisa and stores in SQLite database and provides day to day gains/losses as well.
- Real stock prices updates from NepaliPaisa API.
- Upload Meroshare transactions csv file and get realtime portfolio summary.
- Sector and instrument wise distributions with charts.
- Company wise transactions summary.
- Search for specific company information.
- Update personal credentials anytime.
- Python 3.8+
- FastAPI web framework
- Uvicorn ASGI web server
- Starlette for rendering templates
- Pydantic for data parts
- SQLite3 as a database
- Download Chart.js and jquery.min.js, place it inside
resources/static/jsdirectory to make it work offline.
- Download zip or clone this project and open the project folder in IDE.
- Install all the requirements:
pip install -r requirements.txt- Download sqlite-tools-win-x64 precompiled binaries from Windows section.
- Extract and rename the folder
sqlite3 - Move to path
C:\sqlite3and also setup environment variable path - Open project folder and navigate inside
\dbfolder scripts.sqlcontains SQL query to create schemas.- Create database using command:
sqlite3 database.db '.read scripts.sql'
Above command will create database.db file with necessary schemas.
- Open the project folder and run this command in powershell/cmd:
python -m uvicorn main:app --reload
INFO: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit)
INFO: Started reloader process [4296] using WatchFiles
INFO: Started server process [18944]
INFO: Waiting for application startup.
INFO: Application startup complete.- Now go to
http://127.0.0.1:8000in your browser, you will see following page:
-
Signup and navigate to
resources\static\uploads\example.csvfile to upload the transactions file. To generate your portfolio summary, download Meroshare transactions csv file and add unit price for each transactions asexample.csv. -
After uploading you will see following portfolio:

