Skip to content
This repository was archived by the owner on Jan 14, 2026. It is now read-only.

govindpvenu/glitchess

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

♟️ Glitchess

A full-stack multiplayer chess platform with real-time gameplay, user authentication, and player rankings.

NOTE: This is an early learning project — expect some bugs (hence the name Glitchess). A new version with an updated stack is planned at github.com/govindpvenu/glichess. This repo is now a public archive for reference. Feel free to explore and laugh at my past mistakes!

🔗 Live Demo

Glitchess gameplay demo

Try it live: glitchess.vercel.app

📌: Backend is deployed on Render's free tier. First request may take 30-60 seconds due to cold start.

📦 Repositories

Repository Description
glitchess-frontend React frontend application
glitchess-backend Node.js/Express backend server

🔗 Features

Game Modes

  • Play Online — Real-time multiplayer chess with other players via WebSocket connections
  • Human vs Computer — Play against AI opponent (random move engine)
  • Human vs Human (Local) — Two players on the same device with move validation and highlights

Authentication

  • Email registration with OTP verification
  • Google OAuth integration
  • Secure password hashing with bcrypt
  • JWT-based session management

User Features

  • Customizable user profiles
  • Game statistics tracking and ratings
  • Global player rankings with sortable data tables

Gameplay Features

  • Full chess rule enforcement (checkmate, stalemate, draw, threefold repetition)
  • Move validation with illegal move prevention
  • Move history
  • Game timers
  • Room-based matchmaking with shareable game IDs

UI/UX

  • Sound effects for moves and captures
  • Dark and light theme support
  • Resizable panels for board and move history
  • Toast notifications for game events

🛠️ Tech Stack

Frontend

Technology Purpose
React 18 UI Framework
TypeScript Type Safety
Vite Build Tool
TanStack Router File-based Routing
Redux Toolkit State Management
RTK Query API Caching
Tailwind CSS Styling
shadcn/ui (Radix) UI Components
chess.js Game Logic
react-chessboard Chess Board
Socket.io Client Real-time Communication

Backend

Technology Purpose
Node.js + Express Server Framework
TypeScript Type Safety
MongoDB + Mongoose Database
Socket.io WebSocket Server
Passport.js Authentication
Resend Email Service
bcryptjs Password Hashing

🎓 Learning Objectives

This project demonstrates key concepts in modern web development:

  • Real-Time Communication — WebSocket implementation with Socket.io for live multiplayer gameplay
  • Full-Stack TypeScript — Type-safe development across frontend and backend
  • Authentication & Security — JWT tokens, OAuth 2.0 (Google), password hashing, and session management
  • State Management — Redux Toolkit with RTK Query for efficient API caching
  • RESTful API Design — Structured endpoints for authentication, user management, and game operations
  • Database Design — MongoDB schema design with Mongoose for user data and statistics
  • Modern React Patterns — Hooks, custom hooks, and component composition
  • File-Based Routing — TanStack Router with protected and public route patterns
  • UI/UX Design — Responsive design with Tailwind CSS and accessible shadcn/ui components

🎮 How to Play

Online Multiplayer

  1. Create an account or login
  2. Click "Play Online" from the home screen
  3. Choose your color (white/black) and create a room
  4. Share the Game ID with your opponent
  5. Your opponent joins using the Game ID
  6. Play chess in real-time!

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request to the respective repository.

📄 License

This project is open source and available under the MIT License.

🙏 Acknowledgments


Made with ❤️ by Govind P Venu

About

A full-stack multiplayer chess platform with real-time gameplay, user authentication, and player rankings.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors