Skip to content

Design a file browser (frontend)

Design the web client for browsing files: a folder tree, the files in a folder, opening a file, and uploading new ones.

System designFrontend and full stackStorage, files and linksMid-levelSenior

What to work through

Work through a file browser as a spoken system design interview. Start by clarifying the scope, sketch a working design and explain the trade-offs behind your choices.

  • Show a folder tree that opens folders as the person expands them
  • List the files in the open folder, with name, size and date
  • Open a file and show it in a way that fits its type
  • Upload new files into the open folder, with progress
  • Move through folders with links and the back button

Constraints to discuss

  • A click on a folder or file answers within 200 milliseconds
  • A folder of 1,000 files or more scrolls smoothly
  • An upload survives a dropped connection without starting over
  • The tree works by keyboard and with a screen reader
  • A file from someone else never runs code in the page
Need a starting point?

Watch for these common gaps as you prepare:

  • Fetching and drawing every file of a big folder at once
  • Keeping the current folder only in page state, so back and reload lose it
  • Sending a large file in one request with no way to resume
  • Assuming the server got every byte that was sent
  • Putting a stranger's HTML file straight into the page
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.