Food Delivery Is a Three-Sided Real-Time System
When you order biryani on Zomato, three groups must coordinate in real time: you, the restaurant, and a delivery partner on a bike somewhere nearby. The food has to be cooked and picked up at the right moment, so it's hot when it arrives, and your ETA has to stay honest the whole way.
Zomato (now part of Eternal, which also runs Blinkit) handles this across hundreds of Indian cities, with huge spikes at lunch, dinner and during cricket matches. Here's how a food delivery platform like it is designed.
๐ฏ Quick Answer (30-Second Read)
- Discovery: restaurants near you, filtered by serviceability, open status and delivery time, then ranked.
- Ordering: cart โ payment โ order sent to the restaurant's tablet โ accepted.
- Dispatch: assign a delivery partner timed to the food's prep time, not just "nearest rider."
- Tracking: riders' phones stream location; customers see live position and an updating ETA.
- Peaks: lunch, dinner and match nights; the system must scale and dispatch smartly under load.
- Blinkit (quick commerce) is different: inventory sits in dark stores, so there's no cooking step.
High-Level Architecture
serviceability, ranking"] GW --> ORD["Order service
(state machine)"] ORD --> PAY["Payments"] ORD --> REST["Restaurant service
accept, prep time"] ORD --> DISP["Dispatch / assignment"] LOC --> GEO[("Geo index
riders by area")] GEO --> DISP ETA["ETA models
prep + travel time"] --> DISP ETA --> C DISP --> D ORD --> EV[["Events"]] --> NOTIF["Notifications, tracking,
analytics"]
1. Discovery: What Can Actually Reach You?
A restaurant 6 km away might be great but unable to deliver within a reasonable time. Discovery first filters by serviceability:
- Is your location within the restaurant's delivery area?
- Is it open, and are riders available nearby?
- What's the estimated delivery time right now?
Then it ranks restaurants using relevance, ratings, your past orders, delivery time and offers.
2. The Order as a State Machine
Every transition is an event, so the app, restaurant and rider always agree on the order's state.
3. Dispatch: Timing Is Everything
Dispatch considers:
- Predicted prep time for this restaurant, dish and time of day
- Rider travel time to the restaurant (on real roads)
- Batching: one rider picking up two nearby orders going the same way
- Fairness and earnings for riders
Indian addresses add difficulty: landmarks instead of exact house numbers. Swiggy's engineers have written about learning precise locations from delivery history (How Swiggy Built Logistics Without Addresses).
4. Live Tracking and ETAs
- Riders' apps send location updates every few seconds to a location service.
- Customers' apps subscribe to updates for their order (WebSockets or periodic polling).
- ETA models combine prep time, rider travel time, traffic and historical data, and update as the order progresses.
5. Peak-Hour Scaling
| Challenge | Approach |
|---|---|
| Traffic spikes at 8โ9 pm | Autoscale stateless services, cache menus and restaurant data |
| Riders scarce in an area | Surge fees, rider incentives, longer ETAs shown honestly |
| Restaurants overwhelmed | Temporarily pause or extend prep time estimates |
| Payment provider issues | Multiple payment gateways with routing |
Food Delivery vs Quick Commerce (Blinkit)
| Food delivery (Zomato) | Quick commerce (Blinkit) | |
|---|---|---|
| Supply | Restaurants cook to order | Inventory pre-stocked in dark stores |
| Biggest delay | Prep time | Picking and packing |
| Key system | Prep-time-aware dispatch | Inventory and store placement |
| Typical promise | 30โ40 minutes | Around 10โ15 minutes |
Frequently Asked Questions
How does Zomato assign delivery partners?
Food delivery platforms consider rider locations, travel time to the restaurant, predicted food preparation time, possible order batching and rider fairness. The goal is for the rider to arrive close to when food is ready, rather than simply picking the nearest rider.
How does live order tracking work?
Delivery partners' apps send GPS updates every few seconds to a location service. The customer app subscribes to updates for its order through persistent connections or polling, and ETA models recalculate arrival time as the rider moves.
How would you design Zomato or Swiggy in an interview?
Cover serviceable restaurant discovery and ranking, an order state machine, payments, restaurant acceptance and prep time, prep-time-aware dispatch with batching, a geo index of riders, live tracking, ETA models, and autoscaling for meal-time peaks.
Conclusion
A food delivery platform like Zomato coordinates customers, restaurants and riders in real time: discovery filtered by serviceability, an order state machine, dispatch timed to food readiness, and live tracking with constantly updated ETAs. Quick commerce removes the cooking step, shifting the hard problem to inventory in dark stores.
Sources
- Zomato blog (engineering and product)
- Swiggy Bytes: Swiggy engineering blog
- Outlook Business: Eternal Q4 FY26 results
Last verified: 2 November 2026.
Related reads: How Swiggy Built Logistics Without Addresses ยท Uber System Design ยท Notification System Design ยท Google Maps System Design
I write about system design and how India's tech gets built. Follow on LinkedIn or X, or invite me to speak.