Skip to content

Latest commit

Β 

History

19 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ“ˆ Stockify

AI-Powered Stock Market & Paper Trading Platform

A full-stack investing workspace for exploring live markets, simulating trades, managing portfolios, and getting AI-powered investment insights.


Live Demo GitHub


React TypeScript Vite Node.js MongoDB TailwindCSS Gemini


Launch Stockify β†’

No installation required. A demo account is available directly from the login page.


Stockify

✨ Overview

Stockify is a full-stack stock market management and paper-trading platform that brings market data, portfolio management, simulated trading, and AI-powered research into one focused investing workspace.

Rather than being a simple stock-price dashboard or CRUD portfolio tracker, Stockify provides an end-to-end simulated investing experience.

Users can:

  • πŸ“ˆ Explore live stock market data
  • πŸ’΅ Buy and sell stocks using virtual funds
  • πŸ’Ό Build and track a persistent portfolio
  • πŸ“Š Monitor profit, loss, holdings, and valuation
  • ⭐ Maintain personalized watchlists
  • πŸ“œ Review complete transaction history
  • πŸ”” Receive persistent account notifications
  • πŸ€– Ask an AI investment research assistant
  • 🧠 Analyze portfolio diversification and risk with AI

The application is fully deployed with a React/Vite frontend on Vercel, a Node.js/Express API on Render, and persistent data stored in MongoDB Atlas.

Stockify is a paper-trading and educational application. No real money or securities are involved.


πŸš€ Live Demo

Stockify is deployed and can be used directly without cloning or installing the project.

A Demo Login is available on the authentication page, allowing visitors to explore the platform without creating a new account.

Service Deployment
Frontend Vercel
Backend API Render
Database MongoDB Atlas
Market Data Finnhub
AI Google Gemini

πŸš€ Features

πŸ” Authentication & Accounts

Stockify implements a complete authentication system rather than relying on mocked frontend users.

  • JWT-based authentication
  • bcrypt password hashing
  • User registration
  • Email or username login
  • Demo account
  • Protected API routes
  • Persistent sessions
  • User profile management
  • Password updates
  • Virtual wallet management

Every new account receives virtual funds that can be used for paper trading.


πŸ“ˆ Live Market Data

Stockify integrates with Finnhub to retrieve real financial market data.

Users can:

  • Search publicly traded companies
  • View live stock quotes
  • Explore market movers
  • Track daily price changes
  • View company information
  • Inspect individual stock pages
  • Monitor gains and losses
  • Add stocks directly to a watchlist

Market information is presented through a focused interface designed to avoid the clutter of traditional trading dashboards.


πŸ’΅ Paper Trading

Stockify includes a simulated trading system backed by persistent portfolio and transaction data.

Users can:

  • Buy stocks using virtual funds
  • Sell existing positions
  • Select quantities
  • Track execution prices
  • Monitor remaining wallet balance
  • Persist every transaction
  • Automatically update portfolio holdings

This allows the application to simulate a simplified brokerage workflow without involving real financial transactions.


πŸ’Ό Portfolio Management

Trades automatically update the user's portfolio.

The portfolio dashboard provides information such as:

  • Current holdings
  • Number of shares owned
  • Average purchase price
  • Total investment
  • Current position value
  • Profit and loss
  • Portfolio valuation
  • Available cash
  • Portfolio performance

Portfolio information is stored persistently in MongoDB rather than existing only in frontend state.


⭐ Watchlist

Users can create a personalized collection of stocks they want to monitor.

Features include:

  • Add stocks to watchlist
  • Remove stocks
  • Persistent watchlist storage
  • Live price information
  • Quick access to stock details

πŸ€– AI Investment Assistant

Stockify includes an AI-powered research assistant built using Google Gemini.

Instead of functioning as a generic chatbot, the assistant is designed around investing and financial education.

Users can ask questions such as:

"What does P/E ratio mean?"

"What are the risks of concentrating my portfolio in technology?"

"How does diversification reduce risk?"

"Compare these companies."

"What should I look at before researching a stock?"

The assistant provides contextual explanations and helps users understand market and portfolio concepts.


🧠 AI Portfolio Analyzer

The AI Portfolio Analyzer works with the user's actual Stockify portfolio rather than requiring them to manually describe their holdings.

It evaluates factors such as:

  • Portfolio Health
  • Diversification
  • Cash Utilization
  • Concentration Risk
  • Overall Risk
  • Portfolio Strengths
  • Portfolio Weaknesses
  • Potential Areas for Improvement

The portfolio data is transformed into structured context and analyzed using Google Gemini.

AI-generated output is intended for educational purposes and should not be interpreted as professional financial advice.


πŸ”” Notifications

Stockify maintains persistent notifications for important account activity.

Notifications can be generated for events such as:

  • Stock purchases
  • Stock sales
  • Wallet deposits
  • Account activity

Notifications are stored in MongoDB and remain available between sessions.


πŸ“œ Transaction History

Every simulated trade creates a transaction record.

Users can review:

  • BUY / SELL operation
  • Stock symbol
  • Company name
  • Quantity
  • Execution price
  • Total transaction value
  • Transaction timestamp

This creates a persistent audit trail of portfolio activity.


πŸ“Έ Screenshots

Stockify Dashboard Stockify Market View
Stockify Portfolio Stockify Stock Details
Stockify AI Stockify Portfolio Analysis

πŸ› οΈ Tech Stack

Frontend

Technology Purpose
React Component-based frontend
TypeScript Type-safe application development
Vite Development and production build tooling
React Router Client-side routing
Tailwind CSS Styling
Recharts Financial data visualization
Lucide React Interface icons
Sonner Toast notifications

Backend

Technology Purpose
Node.js JavaScript runtime
Express.js REST API server
TypeScript Type-safe backend development
MongoDB Persistent application database
Mongoose MongoDB ODM and schema modelling
JWT Authentication
bcrypt Password hashing

External Services

Service Purpose
Finnhub API Live stock market data
Google Gemini AI assistant and portfolio analysis
MongoDB Atlas Managed cloud database
Render Backend hosting
Vercel Frontend hosting

🧱 Architecture

                              User
                               β”‚
                               β–Ό
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚   React + Vite     β”‚
                    β”‚      Vercel        β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                              β”‚
                         REST / JSON
                              β”‚
                         JWT Bearer Auth
                              β”‚
                              β–Ό
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚ Node.js + Express  β”‚
                    β”‚       Render       β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                              β”‚
              β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
              β”‚               β”‚               β”‚
              β–Ό               β–Ό               β–Ό
       β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
       β”‚   MongoDB   β”‚ β”‚   Finnhub   β”‚ β”‚   Gemini    β”‚
       β”‚    Atlas    β”‚ β”‚     API     β”‚ β”‚     AI      β”‚
       β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
              β”‚               β”‚               β”‚
              β–Ό               β–Ό               β–Ό
        Users, Trades,    Live Market      AI Research &
        Portfolios &         Data         Portfolio Analysis
        Notifications

πŸ”„ Application Flow

                         Authentication
                               β”‚
                               β–Ό
                           Dashboard
                               β”‚
          β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
          β”‚                    β”‚                     β”‚
          β–Ό                    β–Ό                     β–Ό
       Markets              Portfolio             AI Tools
          β”‚                    β”‚                     β”‚
          β–Ό                    β”‚              β”Œβ”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”
    Stock Details              β”‚              β”‚             β”‚
       β”‚      β”‚                β”‚              β–Ό             β–Ό
       β”‚      β”‚                β”‚         AI Assistant   Portfolio
      BUY    SELL              β”‚                         Analyzer
       β”‚      β”‚                β”‚
       β””β”€β”€β”¬β”€β”€β”€β”˜                β”‚
          β–Ό                    β”‚
      Transaction β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
          β”‚
          β”œβ”€β”€β”€β”€ Update Portfolio
          β”œβ”€β”€β”€β”€ Update Wallet
          └──── Create Notification

🌐 REST API

The backend is organized into domain-specific REST endpoints.

/api/auth
/api/portfolio
/api/transactions
/api/watchlist
/api/notifications
/api/market
/api/ai

Protected endpoints require an authentication token:

Authorization: Bearer <JWT_TOKEN>

Authentication

POST    /api/auth/register
POST    /api/auth/login
GET     /api/auth/me
PATCH   /api/auth/profile
PATCH   /api/auth/password
PATCH   /api/auth/wallet/deposit

The remaining routes handle portfolio operations, transactions, watchlists, notifications, market information, and AI functionality.


πŸ“‚ Project Structure

Stockify/
β”‚
β”œβ”€β”€ client/
β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”œβ”€β”€ app/
β”‚   β”‚   β”‚   β”œβ”€β”€ components/
β”‚   β”‚   β”‚   β”œβ”€β”€ context/
β”‚   β”‚   β”‚   β”œβ”€β”€ hooks/
β”‚   β”‚   β”‚   β”œβ”€β”€ lib/
β”‚   β”‚   β”‚   β”œβ”€β”€ pages/
β”‚   β”‚   β”‚   └── ...
β”‚   β”‚   β”‚
β”‚   β”‚   └── styles/
β”‚   β”‚
β”‚   β”œβ”€β”€ package.json
β”‚   └── vite.config.ts
β”‚
β”œβ”€β”€ server/
β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”œβ”€β”€ config/
β”‚   β”‚   β”œβ”€β”€ controllers/
β”‚   β”‚   β”œβ”€β”€ middleware/
β”‚   β”‚   β”œβ”€β”€ models/
β”‚   β”‚   β”œβ”€β”€ routes/
β”‚   β”‚   β”œβ”€β”€ services/
β”‚   β”‚   └── utils/
β”‚   β”‚
β”‚   β”œβ”€β”€ server.ts
β”‚   β”œβ”€β”€ package.json
β”‚   └── tsconfig.json
β”‚
β”œβ”€β”€ .gitignore
└── README.md

πŸ” Security

Stockify implements several security practices across the application:

  • Passwords hashed using bcrypt
  • JWT-based authentication
  • Protected backend routes
  • Authorization headers for authenticated requests
  • Environment-based secret management
  • Server-side request validation
  • MongoDB authentication
  • Production CORS configuration
  • Separation between frontend and backend credentials

API keys, JWT secrets, and database credentials are never intended to be committed to the repository.


πŸ’» Local Development

You do not need to run Stockify locally to use it.

The complete application is available at stockify-sm.vercel.app.

The following instructions are only for developers interested in running or modifying the source code.

Clone the repository

git clone https://github.com/Kaniska1/Stockify.git
cd Stockify

Install backend dependencies

cd server
npm install

Create server/.env:

PORT=5000

MONGODB_URI=your_mongodb_connection_string

JWT_SECRET=your_jwt_secret

GEMINI_API_KEY=your_gemini_api_key
GEMINI_MODEL=your_gemini_model

FINNHUB_API_KEY=your_finnhub_api_key

Start the backend:

npm run dev

Install frontend dependencies

Open another terminal:

cd client
npm install

Optionally create client/.env:

VITE_API_URL=http://localhost:5000

Start the frontend:

npm run dev

Vite will display the local development URL in the terminal.


🚒 Deployment

Stockify uses separate deployments for the frontend and backend.

GitHub
   β”‚
   β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Ί Vercel
   β”‚                 β”‚
   β”‚                 └── React/Vite Frontend
   β”‚
   └──────────────► Render
                     β”‚
                     └── Node/Express API
                              β”‚
                              β–Ό
                         MongoDB Atlas

Production environment variables are configured independently on the relevant hosting platforms.

Production

Application

https://stockify-sm.vercel.app/

API

https://stockify-api-xsuy.onrender.com/


πŸ§ͺ What This Project Demonstrates

Stockify was built as more than a frontend stock dashboard.

It demonstrates practical experience with:

  • Full-stack TypeScript development
  • REST API design
  • Authentication and authorization
  • MongoDB schema modelling
  • Persistent application state
  • Financial transaction workflows
  • Third-party API integration
  • AI integration with application context
  • Portfolio calculation logic
  • Protected frontend and backend routes
  • Responsive dashboard design
  • Production environment configuration
  • Separate frontend/backend deployments
  • Debugging differences between Windows development and Linux production environments

πŸ—ΊοΈ Roadmap

Potential future improvements include:

  • πŸ“Š Advanced TradingView-style charts
  • πŸ“° Live financial news
  • πŸ”” Custom stock price alerts
  • πŸ” Advanced stock screener
  • πŸ“„ Exportable portfolio reports
  • πŸ“ˆ Historical portfolio performance charts
  • 🧠 Deeper AI stock research
  • πŸ“Š Sector and asset-allocation visualization
  • ⚑ Market-data caching
  • πŸ”„ Real-time updates using WebSockets/SSE
  • πŸ§ͺ Automated API and frontend testing
  • πŸš€ Route-level code splitting and bundle optimization
  • πŸ“± Progressive Web App support
  • 🌍 Multi-currency portfolio support

⚠️ Disclaimer

Stockify is an educational and portfolio project.

The platform performs simulated trades using virtual funds and does not execute real securities transactions.

Market information and AI-generated responses are provided for demonstration and educational purposes only. They should not be considered financial, investment, legal, or tax advice.


🀝 Contributing

Contributions, suggestions, and bug reports are welcome.

If you'd like to contribute:

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Commit your work
  5. Open a pull request

πŸ“„ License

This project is licensed under the MIT License.


πŸ‘¨β€πŸ’» Built by Kaniska Mitra

Built as a full-stack exploration of financial technology, backend architecture, real-time market data, and applied generative AI.

GitHub Stockify


If you found Stockify interesting, consider giving the repository a ⭐

About

AI-Powered Stock Portfolio, Trading & Market Analysis Platform

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages