Skip to content

Design a shopping site, from the listing to the cart (frontend)

Design the web client for a store: a page of products with filters, a page for one product, and a cart.

System designFrontend and full stackShopping, tickets and bookingMid-levelSenior

What to work through

Work through a shopping site, from the listing to the cart as a spoken system design interview. Start by clarifying the scope, sketch a working design and explain the trade-offs behind your choices.

  • Browse a listing of products, filter and sort it, and come back to or share the same view
  • Open a product page with its photos, its options such as size, its price and its stock
  • Add to a cart, change quantities and remove items, as a guest or signed in
  • Keep the cart when the tab closes and the shopper comes back later

Constraints to discuss

  • The main content shows within 2.5 seconds on a phone, at the 75th percentile
  • A tap answers within 200 milliseconds
  • Listing and product pages can be read by search engines
  • Layout shift stays at 0.1 or less while images load
  • Usable with a keyboard and a screen reader
Need a starting point?

Watch for these common gaps as you prepare:

  • Filters kept only in component state, so Back, a refresh and a shared link lose them
  • A history entry for every filter click
  • Blanking the result list while new results load
  • Lazy-loading the first product image, or marking every image high priority
  • Sending the cart total from the browser instead of letting the server price the cart
  • Leaving search engines out of the design
Read: Frontend system design interview questions, and who asks them

Why this question is in the collection

These sources connect the problem to company interview reports or preparation guides. They do not guarantee what a company will ask you.

Your next question

AI systemsDesign a ChatGPT-style chat (frontend)Search and autocompleteDesign an autocomplete search box (frontend)CollaborationDesign a calendar (frontend)Messaging and notificationsDesign a chat app (frontend)
Browse the collection
01

Pick a question

Read the brief and choose what you want to work on.

02

Talk it through

Explain your thinking. Respond to follow-ups. Draw when a design needs it.

03

Find your next improvement

Use the feedback from your interview to decide what to practice next.