Frontend interview questions for 2027: what interviewers ask now and how to answer

Frontend interview questions for 2027, round by round: the screen, JavaScript, machine coding, React, system design and behavioural, and how to answer each.

Intermediate 15 min readBy , updated 23 November 2026

Frontend interviews are organised by rounds, not by topics. A typical loop has a screen, a JavaScript coding round, a UI or machine coding round, a React or framework round, a frontend system design round from mid-level up, and a behavioural round. Each round has a small set of questions that come up again and again. This guide maps the rounds, lists the questions that come up most in each one with a short approach to a strong answer, and links to the full answer or practice question for each. It also covers what has changed recently in React, Next.js, the web platform and interview formats, with dates, so you prepare for the interview as it runs now rather than as it ran three years ago.

Use it as a map. When a question here feels shaky, open the linked page, write the answer or the code yourself, then come back. For the full question lists by topic, the JavaScript interview questions and React interview questions hubs are the place to practise.

The rounds of a frontend loop

Loops differ by company and level, so confirm yours with the recruiter. The shape below is common across big tech, product companies and well-funded startups.

Round Typical length What is scored Practise in
Screen 30 to 60 minutes Fundamentals explained clearly, and one small coding task JavaScript questions, CSS questions
JavaScript coding 45 to 60 minutes A working utility or polyfill, edge cases, complexity Polyfill questions, promise questions
UI or machine coding 60 to 120 minutes A working component, state design, accessibility, extensibility Machine coding questions
React or framework 45 to 60 minutes Rendering model, hooks, data fetching, modern APIs React hooks questions
Frontend system design 45 to 60 minutes Requirements, architecture, data model, API, trade-offs The system design course
Behavioural 45 to 60 minutes Ownership, conflict, impact, level signals Behavioural interview guide

Freshers usually see the first four. System design appears from around two years of experience and often decides the level at SDE-2 and above. Some companies add a DSA round even for frontend roles; DSA for frontend interviews explains how much you need. For what each level is expected to show, read SDE-1 vs SDE-2 vs senior vs staff.

What changed recently

Most of what interviewers ask is stable: closures, the event loop, debounce and an autocomplete were asked five years ago and are still asked. What moves is the React and framework round, the performance vocabulary and, more recently, the format of the coding rounds. These are the changes worth knowing, as of late 2026.

  • INP replaced FID as a Core Web Vital on 12 March 2024. Interaction to Next Paint measures how quickly the page responds to every interaction, not only the first one. A good INP is 200 milliseconds or less at the 75th percentile of page loads. Performance questions now expect INP, not FID, and "how would you fix a slow INP?" is a common follow-up.
  • React 19 became stable on 5 December 2024. It added Actions, useActionState, useOptimistic, the use API, form actions and ref as a prop for function components, so forwardRef is no longer needed in new code. Interviewers now ask how forms and optimistic updates work with these APIs. The React 19 Actions guide covers them.
  • React 19.2 shipped on 1 October 2025 with <Activity>, which hides part of the tree while keeping its state, and useEffectEvent, which separates event logic from an effect so it no longer has to be a dependency. Expect both in effect and stale-closure questions.
  • React Compiler 1.0 was released on 7 October 2025. It memoizes components and hooks automatically at build time. "Do we still need useMemo and useCallback?" is now a standard question.
  • Next.js 16 was released on 21 October 2025. Turbopack became the default bundler, middleware.ts was renamed proxy.ts (the old name is deprecated), Cache Components made caching opt-in with the "use cache" directive, and built-in React Compiler support became stable, though it is not on by default. If your loop includes Next.js, use the new names and know the old ones; see what is middleware in Next.js.
  • Same-document view transitions became Baseline Newly available on 14 October 2025, when Firefox 144 shipped them, so the View Transitions API now works in all three major browser engines. It shows up in UI rounds as "animate this list-to-detail change".
  • A critical vulnerability in React Server Components was disclosed on 3 December 2025 (CVE-2025-55182, remote code execution, fixed in 19.0.1, 19.1.2 and 19.2.1). It made a point interviewers now probe: server components run on the server, so they are part of your server's attack surface and need dependency updates like any backend.
  • Angular 21, released in November 2025, no longer includes zone.js by default and added experimental Signal Forms. Angular loops now lean on signals and zoneless change detection; see signals in Angular.
  • Some companies now run AI-assisted coding rounds. Canva's engineering blog announced on 11 June 2025 that it expects frontend, backend and machine learning candidates to use AI tools such as Copilot, Cursor and Claude in technical interviews. In July 2025 Meta confirmed it was testing coding interviews with an AI assistant, and as of late 2026 its hiring process page says select roles include an authorised AI assistant inside CoderPad, with outside AI tools not allowed. Most loops are still unassisted, so ask the recruiter which format you will get. The Canva and Meta company guides describe those rounds.

What the AI-assisted format changes is what you are scored on: scoping the problem, splitting it into tasks, reading generated code critically, and finding the bug it introduced. It does not remove the need to know the fundamentals, because you cannot review code you could not have written.

Screen questions

The screen checks that you can explain fundamentals clearly and quickly. Answers should be two or three minutes, start with a one-sentence definition, then give a concrete example.

What happens when you type a URL into the browser?

Walk the path in order: URL parsing, DNS lookup, TCP and TLS connection, the HTTP request and response, then parsing HTML into the DOM, CSS into the CSSOM, building the render tree, layout, paint and compositing. Mark what blocks rendering: CSS in the head, and scripts without async or defer. Stop at the level the interviewer wants and offer to go deeper on any step. Full answer: what happens when you type a URL. Practise it as putting the steps from URL to first paint in order.

Explain the event loop

JavaScript runs one call stack. When the stack is empty, the event loop runs every queued microtask (promise callbacks, queueMicrotask, the code after an await), lets the browser render if it is time to, then takes the next task, such as a timer or an event. Then predict a short snippet out loud, because that is the follow-up. Full answer: what is the event loop. Step through examples in the event loop visualizer, then try predicting the order of setTimeout, promises and await.

What is a closure?

A closure is a function together with the variables from the scope it was created in, which it keeps access to after that scope has returned. Give one use (private state in a counter, or a debounced function remembering its timer) and one trap (the var loop bug, or a stale value in a React effect). Full answer: what is a closure in JavaScript.

How does this work?

this is decided by how a function is called, not where it is written: a method call sets it to the object, a plain call leaves it undefined in strict mode, new sets it to the new object, call, apply and bind set it explicitly, and arrow functions take it from the surrounding scope. Show a detached method losing its this. Full answer: how the this keyword works.

How does CSS specificity work?

Compare selectors by counting ids, then classes, attributes and pseudo-classes, then element types; the higher count wins, and source order breaks ties. Inline styles beat selectors, !important beats normal declarations, and with cascade layers, unlayered styles beat layered ones. Full answer: how CSS specificity works. Then predict which colour wins.

What are Core Web Vitals?

Three field metrics: Largest Contentful Paint for loading, Interaction to Next Paint for responsiveness and Cumulative Layout Shift for visual stability. Give the "good" thresholds (2.5 seconds, 200 milliseconds and 0.1) and one fix for each: preload the hero image, break up long tasks, reserve space for images and ads. Full answer: Core Web Vitals: LCP, INP and CLS.

JavaScript coding round

You write a utility from a blank file, usually without a framework. Strong answers state the signature first, handle the edge cases the interviewer is about to ask for, and say the complexity unprompted.

Implement debounce

Return a function that clears the previous timer and sets a new one on every call, then calls the original with the latest arguments and the right this. The follow-ups are leading-edge calls, cancel() and flush(). Practise debounce with cancel and flush, and read debounce vs throttle for the throttle variant.

Implement Promise.all

Return a new promise, resolve each input with Promise.resolve so plain values work, store results by index so order is kept, count settled items, reject on the first rejection, and resolve an empty input immediately. Practise Promise.all from scratch, and compare the combinators in Promise.all vs allSettled vs race vs any.

Implement Function.prototype.bind

Return a function that calls the original with a fixed this and the pre-filled arguments followed by the new ones. The follow-up is new: a bound function called with new ignores the bound this. Practise bind with partial arguments, with call, apply and bind as background.

Implement a deep clone

Recurse through objects and arrays, keep a Map from originals to copies so circular references work, and handle Date, Map and Set explicitly. Mention structuredClone and what it cannot copy, such as functions. Practise deep clone with circular references, with shallow vs deep copy as background.

Run async tasks with a concurrency limit

Start up to N tasks, and each time one finishes start the next, storing results by index. Decide and say what happens on failure: stop, or collect errors. This is the most common senior JavaScript question. Practise mapLimit with N concurrent tasks, and read promise concurrency.

Write a fetch wrapper with a timeout

Create an AbortController, abort it from a timer, pass its signal to fetch, and clear the timer in finally. Combine it with the caller's own signal, and turn an abort into a clear timeout error. Practise a fetch wrapper with timeout and AbortController.

UI and machine coding round

You build a working UI from a written spec, often in React, sometimes in plain JavaScript. Interviewers score whether it runs, how state is modelled, keyboard and screen reader support, and how easily it takes the requirement they add at the end. The machine coding round guide gives a time plan.

Build an autocomplete

Debounce the input, cancel stale requests with AbortController or ignore out-of-order responses, cache results by query, and support arrow keys, Enter and Escape with the combobox ARIA pattern. Show loading, empty and error states. Practise a typeahead with caching and keyboard support.

Build nested comments or a file explorer

Model the tree as a normalised map of ids to nodes with child id lists, so adding, editing and deleting a node is a single update rather than a deep copy of the whole tree. Render recursively, and say how you would handle a very deep thread. Practise nested comments with threaded replies and a file explorer with add, rename and delete.

Build a todo app

The easy question with a high bar: derived state for filters rather than duplicated lists, stable ids as keys, inline editing that handles Enter and Escape, and persistence to localStorage that survives a parse error. Practise a todo app with editing, filters and persistence.

Build infinite scroll

Watch a sentinel element with IntersectionObserver, load the next page with a cursor, guard against duplicate loads while a request is in flight, and stop when there is no more. Mention virtualisation for very long lists. Practise infinite scrolling with IntersectionObserver.

Build accessible tabs or an accordion

Use the right roles (tablist, tab, tabpanel), connect them with aria-controls and aria-labelledby, and implement roving tabindex with arrow keys, Home and End. Interviewers test with the keyboard, so you should too. Practise compound tabs with roving tabindex and an accessible accordion.

React round

React rounds ask you to predict behaviour and explain the rendering model, then write a hook or a small component. Use current APIs and say which version you are describing.

Why does a component re-render?

A component re-renders when its state changes, when its parent re-renders, or when a context it reads changes. Props changing is not a separate trigger: the parent re-rendering is. memo skips a re-render when props are shallowly equal. Full answer: why a React component re-renders. Practise predicting which components re-render.

Why do lists need keys?

Keys tell React which item is which between renders, so it keeps the right state and DOM node with the right item. Index keys break when items are inserted, removed or reordered, because state stays with the position. Full answer: why lists need keys. Practise when React keeps or resets state.

How do useEffect dependencies and cleanup work?

The effect runs after commit and again when a dependency changes; the cleanup runs before the next run and on unmount. Show a fetch with an ignore flag or an abort in cleanup to avoid race conditions, and mention useEffectEvent for logic that should read the latest value without being a dependency. Full answer: how useEffect works. Practise debugging an infinite effect loop and stale responses.

Do we still need useMemo and useCallback with the React Compiler?

Explain what they do (keep a value or function reference stable between renders), then say the compiler now adds that memoization automatically for code that follows the Rules of React. Manual memoization stays valid and is still useful when you need a guaranteed stable reference, such as an effect dependency. Full answer: useMemo vs useCallback. Practise adopting the React Compiler without hiding bugs.

What are Server Components, and how is that different from SSR?

SSR renders the whole tree to HTML on the server and then hydrates it all in the browser. Server Components run only on the server, send no JavaScript for themselves, and can read data directly; "use client" marks where interactive client components begin. Full answers: server vs client components and what is hydration. The React Server Components guide goes deeper.

How do you handle a form with React 19 Actions?

Pass an async function to the form's action, use useActionState for the returned errors and pending state, and useOptimistic to show the result before the server confirms. Mention that React resets the form after a successful action. Read the React 19 Actions guide, then practise a sign-up form with useActionState.

Frontend system design round

You design a product's frontend in 45 to 60 minutes. Use a framework so you spend time where the points are: the RADIO framework (requirements, architecture, data model, interface, optimisations) is a solid default, and the frontend system design interview guide walks through a full round.

Design an autocomplete for millions of users

Clarify the scope (suggestions only, or full search?), then cover debouncing, request cancellation, a client cache with a size limit, server-side prefix ranking, keyboard and screen reader support, and what happens on a slow network. Practise designing an autocomplete system.

Design a news feed

Cursor pagination, a normalised client cache, virtualised rendering, optimistic likes, new-post banners instead of shifting the list, and image loading that does not hurt LCP or CLS. Read the news feed case study, then practise a news feed with infinite scroll.

Design a chat app

WebSocket transport with reconnection, message ordering with server ids, optimistic sends with client ids, an offline outbox, read receipts and a virtualised message list. Read design a chat app, then practise WhatsApp Web.

Design a ChatGPT-style chat UI

A newer prompt that tests streaming: render tokens as they arrive without re-rendering the whole transcript, parse markdown and code blocks incrementally, support stop and regenerate, and keep history and branches. Practise a ChatGPT-style chat UI.

Fix a page with a poor INP

Measure first with field data, find the long tasks behind slow interactions, then yield to the main thread, split work, defer non-urgent updates with transitions and move heavy work to a worker. Read performance in system design, then practise investigating an INP of 600 ms.

Behavioural round

The behavioural round often decides the level. Prepare eight to ten real stories with your own numbers, and tell each in about two minutes with a clear "I". The behavioural interview guide shows how to build the story bank.

Tell me about yourself

Ninety seconds: what you work on now, one result you are proud of, and why this role is the next step. It is a pitch, not your CV read aloud. Full answer: tell me about yourself.

Tell me about a disagreement with a teammate

Pick a real technical disagreement, show that you understood the other view, explain how data or a small experiment settled it, and end with the outcome and the relationship intact. Full answer: a disagreement with a teammate.

Why do you want to work here?

Name something specific about the product or the engineering work, connect it to what you have done, and say what you want to learn. Read the company guide on /companies first. Full answer: why do you want to work here.

What are your strengths and weaknesses?

A strength with evidence, and a real weakness with what you are doing about it. Avoid disguised strengths such as "I work too hard". Full answer: strengths and weaknesses.

What questions do you have for us?

Always ask two or three: how the team ships, what a strong first six months looks like, what the hardest frontend problem is right now. Full answer: questions to ask at the end.

How to use this list

Reading model answers feels productive and builds very little. For each question above, close the page and answer it out loud or write the code from a blank file, with a timer. Mark the ones you could not finish, and redo them a few days later. For coding questions, run your solution against tests rather than checking it by eye.

If you have an interview date, the interview planner turns the company and date into a day-by-day plan. If you want a structured path instead of a list, follow the frontend interview roadmap, and see how to prepare for frontend interviews for the round-by-round approach. To test yourself under pressure, run a timed mock interview.

Where to practise next

Practise it

Each question opens in an editor with tests, so you can check your understanding by writing the code.

  1. Predict the event-loop order of setTimeout, promises, queueMicrotask and awaitEasy15 minFree
  2. Implement debounce() with cancel() and flush()Medium35 minFree
  3. Implement Promise.all() from scratchMedium35 minFree
  4. Build a typeahead/autocomplete with caching and keyboard supportMedium45 minFree
  5. Build a nested comments component with threaded repliesMedium40 minFree
  6. Predict which React components re-render: memo, children props and contextMedium25 min
  7. Adopt the React Compiler without hiding bugs: classify components and order the rolloutHard30 min
  8. Design a news feed with infinite scrollHard60 minFree
  9. Design an autocomplete system serving millions of users with caching and request cancellationHard60 minFree
  10. Design a ChatGPT-style chat UI: streaming responses, markdown and code rendering, stop and regenerate, history and branchingHard60 min