How MongoDB Helped Zepto Reduce Latency by 40%

“Behind Zepto’s 10-minute delivery promise is a database built for speed.”
Zepto MongoDB
Illustration by Diksha Mishra

Zepto, the quick commerce giant, leverages MongoDB Atlas to overcome significant scalability challenges. “Behind Zepto’s 10-minute delivery promise is a database built for speed!” said Sachin Chawla, VP for India & South Asia at MongoDB, in a recent social media post. 

By shifting from a monolithic architecture with relational databases to MongoDB’s NoSQL platform, Zepto reduced latency for its critical APIs by 40%. This change also boosted its ability to handle six times more traffic, improving both operational efficiency and the overall customer experience.

The Challenge: Scaling Quick Commerce

Founded in 2021, Zepto revolutionised the Indian grocery delivery industry with its promise of 10-minute deliveries. However, as Zepto expanded—achieving $1.5 billion in annualised sales by mid-2024—its legacy infrastructure struggled to keep pace. 

Performance bottlenecks, high latency, and an inability to deliver real-time analytics hindered growth and operational efficiency.

A few months ago, during a presentation at MongoDB.local, Mayank Agarwal, senior architect at Zepto, explained: “We had a big monolith, and all the components were powered by PostgreSQL and a few Redis clusters. As our business grew, we faced many performance issues and restrictions on the velocity at which we wanted to operate.”

Zepto’s reliance on Redis clusters for caching also became a bottleneck as the business scaled. Kshitij Singh, technical lead at Zepto, noted, “We had a pretty huge Redis setup which we wanted to get rid of, as we were not able to scale it further. MongoDB’s in-memory caching solved this problem for us.”

Why MongoDB Atlas?

Zepto sought to break its monolithic architecture into microservices and migrate to a NoSQL database to address its issues. After evaluating multiple databases, MongoDB stood out due to its ability to handle nested document structures and array-based queries effectively.

“The queries were very performant, given the required indexes we had created, and that gave us confidence,” said Agarwal. “The biggest motivating factor was when we saw that MongoDB provides in-memory caching, which could address the huge Redis cluster that we couldn’t scale further.”

MongoDB’s Atlas platform also offered features such as real-time data archival and analytical nodes, enabling Zepto to separate customer-facing workloads from internal queries. Singh highlighted: “This ensured that customer performance wasn’t compromised.”

Results: Faster, Scalable, and Reliable

Zepto’s migration to MongoDB Atlas resulted in improved efficiency at an overall operational level. The company witnessed a huge reduction in latency, thereby significantly improving the response times of critical APIs and enhancing the customer experience. 

Additionally, the infrastructure scaled to handle 6x more traffic, ensuring no performance degradation. 

The migration to MongoDB also led to a 14% improvement in page load times, contributing to higher conversion rates and increased sales. MongoDB’s support for analytical nodes enabled Zepto to maintain consistent performance, ensuring effective real-time analytics across the platform.

The shift also streamlined Zepto’s ETL pipelines and archival processes, reducing management overhead and enabling faster deployment of new features.

“Post the migration, we observed a latency reduction of up to 40% for key APIs and handled throughput spikes, such as during campaigns, by enabling data compression and other optimisations. This has made our infrastructure more robust and scalable,” Singh said.

Scaling New Heights with AWS

Zepto’s success story is also powered by its strong partnership with AWS.

“We started Zepto about three years ago with just one dark store in Mumbai. Today, we’ve grown to over 200 dark stores and annualised sales north of INR 10,000 crore,” said Kaivalya Vohra, co-founder of Zepto. “From day one, we were clear that AWS was the way to go.”

AWS’ managed services and support allowed Zepto to launch new features rapidly while optimising costs. “AWS helped us achieve a quick MVP with credits from the AWS Activate program. As we scaled, the collaboration with AWS architects enabled us to come up with solutions no one had tried before,” noted Singh.

Zepto leverages AWS across the entire customer journey, from enhancing product discovery to streamlining last-mile logistics. Generative AI solutions on AWS have also enabled faster resolution times and improved customer satisfaction.

“AWS has been instrumental in helping us scale quickly while optimising costs. Its enterprise support and sponsorship for POCs have been invaluable,” Singh added.

The Pricing Dilemma 

Zepto is currently under fire for differential pricing algorithms on Android and iPhones. Several customers have expressed their frustration on social media platforms, speculating the possible reasons behind the stark difference in prices. 

Some believe the pricing is influenced by demographic and user device data, which could potentially favour Android users. The company has yet to officially comment on this issue.

📣 Want to advertise in AIM? Book here

Picture of Vandana Nair

Vandana Nair

As a rare blend of engineering, MBA, and journalism degree, Vandana Nair brings a unique combination of technical know-how, business acumen, and storytelling skills to the table. Her insatiable curiosity for all things startups, businesses, and AI technologies ensures that there's always a fresh and insightful perspective to her reporting.
Related Posts
Association of Data Scientists
GenAI Corporate Training Programs
Our Upcoming Conference
India's Biggest Conference on AI Startups
April 25, 2025 | 📍 Hotel Radisson Blu, Bengaluru
Download the easiest way to
stay informed

Subscribe to The Belamy: Our Weekly Newsletter

Biggest AI stories, delivered to your inbox every week.