Skip to content

Latest commit

Β 

History

39 Commits

Folders and files

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

Repository files navigation

πŸŽ“ TutorBook

The Best Online Tutor Booking Platform in Bangladesh

Connect with verified, top-rated tutors for personalized learning sessions β€” anytime, anywhere.


Next.js React Tailwind CSS HeroUI Vercel BetterAuth License


🌐 Live Demo Β Β·Β  πŸ› Report Bug Β Β·Β  πŸ’‘ Request Feature


πŸ“‹ Table of Contents


πŸš€ About the Project

TutorBook is a full-stack tutor booking web application that bridges the gap between students and qualified tutors. Students can search, filter, and book verified tutors for one-on-one sessions across 20+ subjects. Tutors can list their profiles, set availability, and manage bookings β€” all in one place.

πŸ† Trusted by 7,500+ learners Β· 200+ verified tutors Β· 14 international awards

Why TutorBook?

  • Students can find the right tutor in under 60 seconds using smart search and date filters
  • Tutors can manage their listings, slots, and sessions from a dedicated dashboard
  • Parents can track session bookings and monitor their child's learning progress

✨ Features

πŸ” Authentication

  • Email & password sign in / sign up with validation
  • Google OAuth one-click login
  • Session-based auth powered by BetterAuth
  • Protected routes for all dashboard pages

πŸ” Tutor Discovery

  • Real-time search by tutor name or subject (debounced 500ms)
  • Date range filter for session start availability
  • Responsive tutor card grid with subject badges and slot status
  • Loading skeleton cards while fetching data
  • Empty state with clear filter option

πŸ“‹ Booking System

  • Book a session via a clean modal form
  • Remaining slot counter (auto-decrements on booking)
  • Cancel a booked session with one click
  • "Fully Booked" state disables the booking button

πŸ§‘β€πŸ« Tutor Dashboard

  • Add new tutors with a rich, multi-section form
  • Edit tutor data via slide-over modal
  • Delete tutor with AlertDialog confirmation
  • Paginated table view of all your listed tutors

πŸ‘€ User Profile

  • View and edit profile (name + photo URL)
  • Avatar with automatic fallback initials
  • Quick navigation links to dashboard pages

🎨 UI / UX

  • πŸŒ™ Light & Dark mode via next-themes
  • πŸ“± Fully responsive β€” mobile, tablet, desktop
  • Animated 3-slide hero carousel (Swiper.js with autoplay)
  • Toast notifications via react-hot-toast
  • Custom 404 Not Found page
  • Global Error boundary page with retry button
  • Sticky frosted-glass navbar with blur effect

πŸ› οΈ Tech Stack

Category Technology
Framework Next.js 16 β€” App Router, Server Components
UI Library React 19
Styling Tailwind CSS v4
Component Library HeroUI v3 β€” Modal, Drawer, Table, Select
Authentication BetterAuth v1 + MongoDB Adapter
Slider / Carousel Swiper.js v12
Icons @gravity-ui/icons + Iconify
Styled Buttons styled-components v6
Lottie Animations @lottiefiles/dotlottie-react
Notifications react-hot-toast
Theme Switching next-themes
Token Handling jsonwebtoken
Deployment Vercel

πŸ“Έ Screenshots

πŸ’‘ Visit the live demo: tutor-booking-client.vercel.app

Page Description
🏠 Homepage 3-slide hero, stats bar, tutor cards, features grid, CTA banner
πŸ“š Tutors Page Real-time search + date filter, skeleton loading, empty state
πŸ“„ Tutor Details Full profile with info rows, booking modal with slot counter
βž• Add Tutor Multi-section form β€” Basic Info + Session Details
πŸ“‹ My Tutors Data table with edit modal + delete confirmation
πŸ“… Booked Sessions Session table with status badges and cancel action
πŸ‘€ Profile Avatar, info rows, edit profile modal
πŸ” Login / Signup Auth forms with Google OAuth, password toggle, validation

🏁 Getting Started

Prerequisites

Installation

# 1. Clone the repository
git clone https://github.com/yourusername/tutor-booking-client.git

# 2. Move into the project folder
cd tutor-booking-client

# 3. Install all dependencies
npm install

# 4. Copy the env example and fill in your values
cp .env.example .env.local

# 5. Start the development server
npm run dev

Open http://localhost:3000 in your browser. βœ…

Available Scripts

Script Description
npm run dev Start the development server
npm run build Create a production build
npm run start Start the production server
npm run lint Run ESLint checks

πŸ”‘ Environment Variables

Create a .env.local file in the root and populate it:

# ── Backend API ──────────────────────────────
NEXT_PUBLIC_SERVER_URL=http://localhost:5000

# ── BetterAuth ───────────────────────────────
BETTER_AUTH_SECRET=your_better_auth_secret_here
BETTER_AUTH_URL=http://localhost:3000

# ── Google OAuth ─────────────────────────────
GOOGLE_CLIENT_ID=your_google_client_id
GOOGLE_CLIENT_SECRET=your_google_client_secret

# ── MongoDB ──────────────────────────────────
MONGODB_URI=your_mongodb_connection_string

⚠️ Never commit .env.local to version control. It is listed in .gitignore by default.


πŸ”Œ API Endpoints

The client communicates with a custom REST API backend:

Method Endpoint Description
GET /tutors Fetch all tutors β€” supports ?search, ?startDate, ?endDate
GET /tutors/:id Fetch a single tutor by ID
POST /tutors Create a new tutor listing
PATCH /tutors/:id Book a session β€” decrements remainingSlots
GET /tutorsFeatures Fetch featured tutors for homepage
GET /myTutors/:userId Fetch tutors created by a specific user
PATCH /myTutor/:id Update tutor details
DELETE /myTutor/:id Permanently delete a tutor
GET /tutorBookedData Fetch all booked sessions
PATCH /tutorBookedData/:id Cancel a booked session

πŸ“„ Pages & Routes

Route Page Protected
/ Homepage ❌ Public
/tutors All Tutors (search + filter) ❌ Public
/tutors/[id] Tutor Details + Book Session ❌ Public
/login Login ❌ Public
/signup Signup ❌ Public
/about Testimonials ❌ Public
/services FAQ ❌ Public
/contact Contact Form ❌ Public
/addTutor Add New Tutor βœ… Auth Required
/myTutors Manage My Tutors βœ… Auth Required
/bookedSessions My Booked Sessions βœ… Auth Required
/profile User Profile βœ… Auth Required

πŸ‘¨β€πŸ’» Author

Takebul Islam

Portfolio LinkedIn GitHub Email


🀝 Contributing

Contributions, issues and feature requests are welcome!

  1. Fork the repository
  2. Create your feature branch β€” git checkout -b feature/AmazingFeature
  3. Commit your changes β€” git commit -m 'Add AmazingFeature'
  4. Push to the branch β€” git push origin feature/AmazingFeature
  5. Open a Pull Request

πŸ“„ License

This project is licensed under the MIT License β€” see the LICENSE file for details.


Made with ❀️ by Takebul Islam

⭐ If you found this project helpful, please give it a star!

GitHub stars GitHub forks

About

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages