Track your competitive programming journey with real-time statistics from Codeforces and LeetCode.
- ✅ Real-time stats from Codeforces & LeetCode APIs
- ✅ JWT-based authentication
- ✅ Beautiful, responsive dashboard
- ✅ Rating progress charts
- ✅ Problem-solving statistics
- ✅ Server-side caching for better performance
- ✅ Rate limiting and security features
- React 19
- Vite
- TailwindCSS
- Chart.js
- React Router
- Axios
- Node.js + Express
- JWT Authentication
- Axios (API proxy)
- Node-cache (server-side caching)
- Rate limiting
- Node.js 18+ installed
- npm or yarn
cd algohustle
./start.shThis will:
- Install dependencies for both frontend and backend
- Start backend on
http://localhost:5000 - Start frontend on
http://localhost:5173
Terminal 1 - Backend:
cd backend
npm install
npm run devTerminal 2 - Frontend:
cd Frontend
npm install
npm run dev- Backend will run on:
http://localhost:5000 - Frontend will run on:
http://localhost:5173 - Open
http://localhost:5173in your browser - Enter a Codeforces username (try "tourist" or "benq")
- Click "Track My Progress"
- Explore your dashboard!
algohustle/
├── backend/ # Node.js + Express API
│ ├── routes/ # API routes
│ ├── middleware/ # Auth & error handling
│ ├── config/ # Database & config
│ └── server.js # Main server file
│
├── Frontend/ # React + Vite app
│ ├── src/
│ │ ├── components/ # React components
│ │ ├── pages/ # Page components
│ │ ├── context/ # React context
│ │ └── utils/ # API utilities
│ └── index.html
│
├── DEPLOYMENT.md # Full deployment guide
└── start.sh # Quick start script
POST /api/auth/login- Login with Codeforces/LeetCode usernamePOST /api/auth/verify- Verify JWT token
GET /api/profile/me- Get current user profilePUT /api/profile/me- Update profileGET /api/profile/:userId- Get public profile
GET /api/cf/:handle- Get Codeforces statisticsGET /api/lc/:handle- Get LeetCode statisticsGET /api/cf/search/:handle- Search Codeforces user
PORT=5000
NODE_ENV=development
JWT_SECRET=your_secret_keyVITE_API_URL=http://localhost:5000/api# Health check
curl http://localhost:5000/
# Test login
curl -X POST http://localhost:5000/api/auth/login \
-H "Content-Type: application/json" \
-d '{"codeforces":"tourist"}'
# Test Codeforces stats
curl http://localhost:5000/api/cf/tourist- Open http://localhost:5173
- Try logging in with username "tourist"
- Check if dashboard loads with real data
- Open browser console (F12) to check for errors
See DEPLOYMENT.md for detailed deployment instructions for:
- Render.com (FREE)
- Railway
- Vercel
- Heroku
Quick deployment summary:
- Push code to GitHub
- Deploy backend to Render/Railway
- Deploy frontend to Vercel/Render
- Update environment variables
- Done!
cd backend
npm run dev # Uses nodemon for auto-reloadcd Frontend
npm run dev # Vite hot reloadBackend:
cd backend
npm startFrontend:
cd Frontend
npm run build # Creates optimized build in dist/
npm run preview # Preview production build- Basic authentication
- Codeforces integration
- LeetCode integration
- Dashboard with stats
- Server-side caching
- Friends system
- Contest reminders
- Email notifications
- Firebase integration
- Mobile app
- Check if port 5000 is available
- Verify
.envfile exists - Run
npm installin backend folder
- Check
VITE_API_URLin Frontend/.env - Verify backend is running on port 5000
- Check browser console for CORS errors
- Ensure backend CORS is configured correctly
- Check if frontend URL is whitelisted in backend
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
MIT License
For issues or questions:
- Check DEPLOYMENT.md for common issues
- Open an issue on GitHub
- Check browser console & backend logs
Built with ❤️ by competitive programmers, for competitive programmers.
Happy Coding! 🚀