Design a scalable hotel reservation frontend using Next.js (like Booking.com / Agoda).
💬 Interview opening:
“Before designing the solution, I’d like to clarify the requirements.”
💬 Say this clearly:
“Next.js is a good choice because it supports SSR, SSG, and ISR, which are critical for SEO and performance in travel platforms.”



💬 Interview line:
“Static assets and pages are served from CDN, while dynamic pages are rendered on demand.”
/app/searchpage.tsx // SSR/hotel/[id]page.tsx // SSG + ISR/bookingpage.tsx // CSR/confirmationpage.tsx
| Page | Strategy | Why |
|---|---|---|
| Search | SSR | SEO + fresh data |
| Hotel detail | SSG + ISR | Fast + scalable |
| Booking | CSR | Secure & user-specific |
| Payment | CSR | Sensitive data |
💬 Interview gold:
“I use the right rendering strategy per page instead of forcing SSR everywhere.”



/search?location=Hanoi💬 Strong line:
“Search parameters are stored in the URL to allow sharing and refresh.”
| Data | Solution |
|---|---|
| Search params | URL |
| Search results | React Query |
| Filters | Local state |
| Selected room | Global store |
| Booking progress | Session / memory |
💬 Interview sentence:
“Server state is managed with React Query to avoid overusing global stores.”



💬 Say this:
“ISR allows us to rebuild hotel pages periodically without redeploying.”



💬 Important line:
“Availability is always rechecked before payment to prevent double booking.”
next/image for optimized images💬 Interview phrase:
“Images are the biggest performance bottleneck in travel apps, so optimization is critical.”
“I design the hotel reservation frontend using Next.js to leverage SSR for SEO-heavy search pages, SSG with ISR for scalable hotel detail pages, and CSR for secure booking flows. The app is structured by routes and features, server state is managed efficiently, and performance, reliability, and security are prioritized throughout the booking journey.”