Skip to content
Resume Studioby M2Toolkit

20 role-specific questions

Full Stack Developer Interview Questions & Answers

Full stack interviews check that you can deliver a feature end to end: an accessible, fast UI, a well-designed API, a sensible data model, and the judgement to know where logic belongs.

Free, no sign-up. 120 questions in this role's practice pool, including behavioural, HR and situational questions.

HTML, CSS & the browser interview questions

Semantics, accessibility, CSS layout, web performance and how browsers render — the fundamentals behind every front-end role.

  1. 1.

    Why does semantic HTML matter? Give examples.

    BeginnerTechnical

    What the interviewer is evaluating

    Accessibility and quality awareness, not just visual output.

    Key points a strong answer covers

    • Meaningful elements. Use elements for their meaning: <nav>, <main>, <button>, <article>.
    • Accessibility. Assistive technology relies on semantics for landmarks, roles and keyboard behaviour.
    • SEO / machines. Search engines and other tools understand the structure better.
    • div button problem. A clickable <div> isn't focusable or keyboard operable; <button> is, for free.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Using headings for font size rather than structure.
    • Building buttons from divs.

    Likely follow-up questions

    • What does a <button> give you that a <div onClick> doesn't?
    • How should heading levels be structured on a page?
    Example strong answer

    Semantic HTML means using elements for what they are, not how they look: <header>, <nav>, <main>, <article>, <button>, a single logical heading outline. It matters mostly for accessibility: screen-reader users jump between landmarks and headings, and a real <button> is focusable, announced as a button and works with Enter and Space automatically — a <div onClick> gives you none of that. It also helps search engines understand the page and makes the code easier to read. Accessibility audits I've done usually find most problems come from non-semantic markup, so fixing that first is cheap and effective.

    Practise this question and get feedback
  2. 2.

    How do you make a web application accessible?

    IntermediateTechnical

    What the interviewer is evaluating

    Practical accessibility knowledge beyond buzzwords.

    Key points a strong answer covers

    • Semantics first. Native elements and proper labels before ARIA.
    • Keyboard. Everything usable by keyboard with a visible focus; manage focus in dialogs.
    • Contrast / text. Sufficient contrast, alt text, text that resizes.
    • ARIA used carefully. ARIA only when there's no native equivalent; live regions for updates.
    • Testing. Test with axe/Lighthouse and a real screen reader; follow WCAG 2.2 AA.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Adding ARIA to everything instead of using native elements.
    • Relying only on automated tools.

    Likely follow-up questions

    • How would you build an accessible modal dialog?
    • What can automated tools not catch?
    Example strong answer

    I start with semantics: native elements, labelled form fields and a sensible heading structure — that solves most issues. Then keyboard: every action reachable by Tab, a visible focus style, and focus managed properly in modals and menus — moved in on open, trapped, returned on close. Colour contrast of at least 4.5:1 for body text, meaningful alt text, and layouts that survive 200% zoom. ARIA only where there's no native option — aria-live for toast messages, aria-expanded on a disclosure. I test with axe in CI, then manually with the keyboard and VoiceOver or NVDA, because automated tools catch maybe a third of issues. WCAG 2.2 AA is the usual target.

    Practise this question and get feedback
  3. 3.

    Explain the CSS box model and box-sizing: border-box.

    BeginnerTechnical

    What the interviewer is evaluating

    Whether you understand how element sizes are calculated — the root of many layout bugs.

    Key points a strong answer covers

    • Four layers. Every box is content, padding, border and margin.
    • content-box default. By default width applies to the content, so padding and border make it wider.
    • border-box. border-box makes width include padding and border — easier to reason about.
    • Margin collapse. Vertical margins between blocks can collapse.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Not knowing why an element with width: 100% and padding overflows.
    • Forgetting margin collapsing.

    Likely follow-up questions

    • When do vertical margins collapse?
    • How does box-sizing affect a flex item's size?
    Example strong answer

    Every element is a box made of content, then padding, then border, then margin outside. With the default box-sizing: content-box, width sets only the content, so a width: 100% element with 20px padding ends up wider than its parent and overflows. With border-box, width includes padding and border, so the element is exactly the width you set — that's why most resets apply *, *::before, *::after { box-sizing: border-box }. Margins sit outside the border and don't count, and adjacent vertical margins between blocks can collapse into one, which surprises people.

    Practise this question and get feedback
  4. 4.

    When would you use Flexbox and when CSS Grid?

    BeginnerTechnical

    What the interviewer is evaluating

    Whether you choose the layout tool that fits the problem rather than forcing one everywhere.

    Key points a strong answer covers

    • Flexbox one dimension. Flexbox lays items out along one axis.
    • Grid two dimensions. Grid controls rows and columns together.
    • Content vs layout first. Flex is content-driven; Grid defines the layout and places content into it.
    • Examples. Flex for toolbars and nav bars; Grid for page layouts, galleries, card grids.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Using Grid or Flex dogmatically for everything.
    • Not knowing gap works in Flexbox too.

    Likely follow-up questions

    • How would you build a responsive card grid without media queries?
    • How do you centre an element both ways?
    Example strong answer

    Flexbox is for one dimension — a row or a column — and it's content-driven: items size themselves and you distribute space, which is perfect for a nav bar, a toolbar, or aligning an icon with text. Grid is two-dimensional: you define rows and columns and place items into them, so it suits page layouts, dashboards and card galleries — grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)) gives a responsive card grid without media queries. They combine well: a Grid page layout with Flexbox inside each card. Both support gap, and centring is just display: grid; place-items: center.

    Practise this question and get feedback
  5. 5.

    What happens between typing a URL and seeing the page? Focus on how the browser renders it.

    IntermediateTechnical

    What the interviewer is evaluating

    End-to-end understanding of loading and rendering.

    Key points a strong answer covers

    • Network. DNS lookup, connection (TCP/TLS), HTTP request, response.
    • Parse HTML / DOM. The browser parses HTML into the DOM.
    • CSSOM / render blocking. CSS builds the CSSOM; CSS and synchronous scripts block rendering.
    • Layout and paint. DOM + CSSOM → render tree → layout → paint → composite.
    • Scripts. Use defer/async so scripts don't block parsing.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Skipping the network part entirely.
    • Not mentioning what blocks rendering.

    Likely follow-up questions

    • What's the difference between async and defer?
    • What causes a layout (reflow), and why is it expensive?
    Example strong answer

    First the network: a DNS lookup, then a TCP and TLS connection, then the HTTP request — often served by a CDN. As the HTML streams in, the browser parses it into the DOM and discovers other resources. CSS is render-blocking: the browser builds the CSSOM before it paints. A plain <script> blocks parsing too, which is why I use defer or modules. The DOM and CSSOM combine into a render tree; layout calculates each box's position and size; paint fills pixels; and compositing assembles layers on the GPU. To speed it up: small critical CSS, deferred scripts, preloading the LCP image and fonts, and avoiding layout-triggering work after load.

    Practise this question and get feedback
  6. 6.

    What are Core Web Vitals, and how would you improve each one?

    IntermediateTechnical

    What the interviewer is evaluating

    Measurable performance knowledge.

    Key points a strong answer covers

    • LCP. LCP measures loading — when the largest content element appears (good ≤ 2.5s).
    • INP. INP measures responsiveness to interactions (good ≤ 200ms). It replaced FID.
    • CLS. CLS measures visual stability (good ≤ 0.1).
    • Fixes. LCP: optimise and preload the hero; INP: break up long tasks; CLS: reserve space for media and ads.
    • Field data. Measure with field data (CrUX, RUM), not only Lighthouse.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Still citing FID as the responsiveness metric.
    • Only quoting Lighthouse lab scores.

    Likely follow-up questions

    • What's the difference between lab and field data?
    • What usually causes a poor INP?
    Example strong answer

    Core Web Vitals are Google's user-centred metrics. LCP, Largest Contentful Paint, measures loading — good is 2.5 seconds or less; I improve it by serving a compressed, correctly sized hero image, preloading it, using a CDN and removing render-blocking resources. INP, Interaction to Next Paint, replaced FID and measures responsiveness — good is 200 ms or less; it's usually hurt by long JavaScript tasks, so I split work up, defer non-essential scripts and reduce hydration cost. CLS measures layout shift — good is 0.1 or less; I reserve space for images, ads and embeds and avoid font swaps that shift text. I track field data from real users, not just Lighthouse.

    Practise this question and get feedback
  7. 7.

    What is CORS, and why do you get CORS errors?

    IntermediateTechnical

    What the interviewer is evaluating

    Understanding of the same-origin policy and where to fix CORS issues.

    Key points a strong answer covers

    • Same-origin policy. Browsers block reading responses from a different origin by default.
    • Server opts in. The server opts in with Access-Control-Allow-Origin and related headers.
    • Preflight. Non-simple requests trigger an OPTIONS preflight first.
    • Fix on the server. It's fixed on the server (or via a proxy), not in front-end code.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Trying to fix CORS in the frontend fetch call.
    • Setting Access-Control-Allow-Origin: * with credentials.

    Likely follow-up questions

    • Why doesn't Postman show CORS errors?
    • What changes when the request includes cookies?
    Example strong answer

    CORS is a relaxation of the browser's same-origin policy. By default a page on app.example.com can send a request to api.other.com, but the browser won't let the JavaScript read the response unless the server says it's allowed, with headers like Access-Control-Allow-Origin. For non-simple requests — say a PUT, or a JSON content type, or a custom header — the browser first sends an OPTIONS preflight to ask permission. So a CORS error is fixed on the server: allow the specific origin, methods and headers, or route through a same-origin proxy. Tools like Postman don't enforce it because it's a browser rule. With cookies you need credentials: 'include' and a specific origin, not *.

    Practise this question and get feedback
  8. 8.

    Compare cookies, localStorage, sessionStorage and IndexedDB.

    BeginnerTechnical

    What the interviewer is evaluating

    Choosing client storage safely.

    Key points a strong answer covers

    • Cookies sent to server. Cookies go with every request to their domain; httpOnly cookies are invisible to JavaScript.
    • localStorage persists. localStorage persists, is synchronous, string-only, ~5MB per origin.
    • sessionStorage per tab. sessionStorage is cleared when the tab closes.
    • IndexedDB. IndexedDB is async and stores large structured data and blobs.
    • Security. Don't keep auth tokens where XSS can read them; prefer httpOnly cookies.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Storing JWTs in localStorage without considering XSS.
    • Storing large data in cookies.

    Likely follow-up questions

    • Why is localStorage a poor place for an auth token?
    • When would you reach for IndexedDB?
    Example strong answer

    Cookies are small and sent automatically with every request to their domain, which makes them the right place for a session — as httpOnly, Secure and SameSite, JavaScript can't read them, which protects against token theft through XSS. localStorage persists across sessions, is synchronous and string-only with roughly 5 MB per origin — fine for preferences like the theme, but any script on the page can read it, so not for tokens. sessionStorage is the same but per tab and cleared when it closes — handy for a form draft. IndexedDB is asynchronous and stores large structured data and files, which is what offline apps and editors use.

    Practise this question and get feedback
  9. 9.

    How do you protect a front-end application against XSS and CSRF?

    AdvancedTechnical

    What the interviewer is evaluating

    Security awareness for the client side.

    Key points a strong answer covers

    • XSS = injected script. XSS is untrusted content executing as script in your page.
    • Escape / avoid raw HTML. Frameworks escape by default; avoid raw HTML or sanitise it (DOMPurify).
    • CSP. A Content Security Policy limits which scripts can run.
    • CSRF. CSRF tricks a logged-in browser into sending a request.
    • CSRF defences. SameSite cookies, CSRF tokens and checking the Origin header.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Thinking React makes XSS impossible.
    • Confusing CSRF with XSS.

    Likely follow-up questions

    • How can XSS still happen in a React app?
    • Why do SameSite cookies help against CSRF?
    Example strong answer

    XSS is when untrusted content runs as script in your page — a comment containing <script> or an onerror attribute. React and other frameworks escape text by default, so the risks are the escape hatches: dangerouslySetInnerHTML, innerHTML, and javascript: URLs in links. I avoid raw HTML, and when I must render it — rich text from a CMS — I sanitise it with DOMPurify. A Content Security Policy is a second layer that blocks inline and unknown scripts. CSRF is different: another site makes the user's browser send a request with their cookies. SameSite=Lax or Strict cookies block most of it, and for sensitive actions I add CSRF tokens or check the Origin header.

    Practise this question and get feedback
  10. 10.

    How do you build a responsive layout?

    BeginnerTechnical

    What the interviewer is evaluating

    Practical mobile-first CSS.

    Key points a strong answer covers

    • Mobile first. Start with the small-screen layout and add breakpoints with min-width.
    • Fluid units. Use fluid units, clamp() and fr instead of fixed pixels.
    • Flexible layout. Grid and Flexbox that wrap naturally.
    • Responsive media. Images with max-width: 100% and srcset/sizes.
    • Container queries / testing. Container queries for components; test on real devices.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Designing desktop first and patching mobile.
    • Fixed-width containers causing horizontal scroll.

    Likely follow-up questions

    • What do container queries solve that media queries don't?
    • Why use rem for font sizes?
    Example strong answer

    I work mobile first: base styles for small screens, then min-width breakpoints where the content needs them rather than for specific devices. Layouts use Grid and Flexbox that wrap on their own — repeat(auto-fill, minmax(…)) handles a lot without breakpoints — with fluid units like %, fr and rem, and clamp() for typography that scales smoothly. Images get max-width: 100% and srcset with sizes so phones download smaller files. For components that appear in different widths, like a card in a sidebar or main column, container queries are better than viewport media queries. I check for horizontal scrolling and test on real phones, not just DevTools.

    Practise this question and get feedback

APIs & back-end architecture interview questions

API design, HTTP, caching, queues, microservices, reliability and observability — language-agnostic back-end questions.

  1. 1.

    Design a REST endpoint for creating an order. Which method, status codes and error responses would you use?

    IntermediateTechnical

    What the interviewer is evaluating

    Clean, predictable API design.

    Key points a strong answer covers

    • POST to a collection. POST /orders creates an order.
    • 201 + Location. Return 201 Created with the new resource (and a Location header).
    • Validation errors. 400/422 with a consistent error body listing field errors.
    • Auth errors. 401 if not authenticated, 403 if not allowed.
    • Idempotency. An Idempotency-Key header prevents duplicate orders on retries.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Returning 200 with { success: false } for errors.
    • Using GET or verbs in URLs like /createOrder.

    Likely follow-up questions

    • How would you make this safe to retry if the client times out?
    • How would you version this API?
    Example strong answer

    I'd use POST /orders with a JSON body of items and a shipping address. On success, 201 Created with the created order and a Location: /orders/{id} header. Invalid input returns 422 (or 400) with a consistent error body — I like RFC 9457 problem details listing each field error. Unauthenticated requests get 401, and 403 if the user can't order for that account. A product that's out of stock might be 409 Conflict. Because clients retry on timeouts, I'd accept an Idempotency-Key header: the server stores the key with the result, and a retry with the same key returns the original order instead of creating a duplicate.

    Practise this question and get feedback
  2. 2.

    What's the difference between PUT and PATCH, and what does idempotent mean?

    BeginnerTechnical

    What the interviewer is evaluating

    Precise understanding of HTTP semantics, which decides how safe retries are.

    Key points a strong answer covers

    • PUT replaces. PUT replaces the resource with the representation sent.
    • PATCH partial. PATCH applies a partial update.
    • Idempotent meaning. Idempotent: repeating the same request leaves the server in the same state.
    • Which are idempotent. GET, PUT and DELETE are idempotent; POST isn't; PATCH may or may not be.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Saying POST is idempotent.
    • Confusing idempotent with safe (no side effects).

    Likely follow-up questions

    • Is DELETE idempotent if the second call returns 404?
    • Why does idempotency matter for retries?
    Example strong answer

    PUT replaces the whole resource with what you send — fields you leave out are effectively removed or reset. PATCH sends only the changes, like { "status": "shipped" }. Idempotent means making the same request once or ten times leaves the server in the same state. GET, PUT and DELETE are idempotent; POST is not, because each call usually creates something new; PATCH can be either, depending on the operation — 'set status to shipped' is, 'add 1 to quantity' isn't. DELETE stays idempotent even if the second call returns 404, because the state is the same. It matters because networks fail and clients retry, and idempotent requests are safe to retry.

    Practise this question and get feedback
  3. 3.

    Where and how would you add caching to a slow API?

    IntermediateTechnical

    What the interviewer is evaluating

    Caching strategy and the invalidation problem.

    Key points a strong answer covers

    • Layers. Cache at the HTTP/CDN layer, in the app (Redis), or in the database.
    • Cache-aside. Cache-aside: check the cache, on a miss load and store.
    • Expiry & invalidation. Choose TTLs and invalidate on writes.
    • What not to cache. Be careful with per-user and strongly consistent data.
    • Stampede. Prevent stampedes with locks, jitter or stale-while-revalidate.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Adding a cache without an invalidation plan.
    • Caching per-user responses publicly.

    Likely follow-up questions

    • What is a cache stampede and how do you prevent it?
    • How do Cache-Control headers interact with a CDN?
    Example strong answer

    First I'd confirm what's slow and how often the data changes. For public, rarely changing responses, HTTP caching with Cache-Control lets the CDN and browsers serve them without touching the server. For expensive queries I'd use cache-aside in Redis: check the cache, on a miss load from the database and store the result with a TTL. On writes I invalidate or update the affected keys, so users don't see stale data for long. I'm careful with per-user data — it must never be cached under a shared key. And for very hot keys I'd prevent a stampede when they expire, with a short lock, TTL jitter or serving stale while one request refreshes.

    Practise this question and get feedback
  4. 4.

    When would you use a message queue, and what problems does it introduce?

    IntermediateTechnical

    What the interviewer is evaluating

    Asynchronous architecture and its trade-offs.

    Key points a strong answer covers

    • Decouple / async work. Queues move slow or non-urgent work out of the request path and decouple services.
    • Absorb spikes. They absorb traffic spikes so workers process at their own pace.
    • Delivery guarantees. Most queues are at-least-once, so consumers must be idempotent.
    • Failure handling. Retries with backoff and a dead-letter queue for failed messages.
    • Examples. RabbitMQ, SQS, Kafka, BullMQ.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Assuming each message is delivered exactly once.
    • No plan for messages that keep failing.

    Likely follow-up questions

    • How do you make a consumer idempotent?
    • When would you choose Kafka over RabbitMQ?
    Example strong answer

    I'd use a queue when work doesn't need to finish inside the request — sending emails, generating reports, processing uploads — or to decouple services, so the order service publishes 'order placed' and billing and shipping consume it independently. Queues also absorb spikes: workers drain the backlog at their own pace. The trade-offs: most queues guarantee at-least-once delivery, so a message can arrive twice and consumers must be idempotent, for example by recording processed message ids. Messages that keep failing need retries with backoff and then a dead-letter queue to inspect. You also need monitoring of queue depth and age, and the system becomes eventually consistent.

    Practise this question and get feedback
  5. 5.

    Monolith or microservices? How would you decide?

    AdvancedTechnical

    What the interviewer is evaluating

    Architectural judgement rather than following trends.

    Key points a strong answer covers

    • Monolith benefits. A monolith is simpler to build, deploy, debug and keep consistent.
    • Microservices benefits. Microservices allow independent deployment and scaling and suit many autonomous teams.
    • Costs of distribution. They add network failures, eventual consistency, and operational and observability overhead.
    • Modular monolith / boundaries. Start with a modular monolith with clear boundaries; extract services when there's a real need.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Choosing microservices for a small team on a new product.
    • Splitting services that share a database.

    Likely follow-up questions

    • What is a distributed monolith?
    • How would you extract the first service from a monolith?
    Example strong answer

    It depends on the team and the problem more than the technology. A monolith is one codebase and one deployment: simpler to build, test, debug and keep consistent, which is usually right for a new product or a small team. Microservices pay off when several teams need to deploy independently, or parts of the system have very different scaling or reliability needs. But they bring network failures, eventual consistency, distributed tracing and much more operational work. My default is a modular monolith with clear domain boundaries and no cross-module database access, and extracting a service only when there's a concrete reason, like an image-processing workload that needs to scale separately.

    Practise this question and get feedback
  6. 6.

    How do you make a back-end service observable in production?

    IntermediateTechnical

    What the interviewer is evaluating

    Operational maturity.

    Key points a strong answer covers

    • Logs. Structured logs with request/correlation ids.
    • Metrics. Metrics for latency, traffic, errors and saturation.
    • Tracing. Distributed tracing (OpenTelemetry) across services.
    • Alerting / SLOs. Alerts on user-facing symptoms tied to SLOs.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Logging unstructured text without request ids.
    • Alerting on every CPU spike instead of user impact.

    Likely follow-up questions

    • What would you alert on for an API?
    • How do traces help debug a slow request across services?
    Example strong answer

    I cover the three pillars. Logs are structured JSON with a request or correlation id on every line, so one request can be followed end to end, and no sensitive data. Metrics track the golden signals — latency percentiles, request rate, error rate and saturation — on dashboards in something like Prometheus and Grafana. Distributed tracing with OpenTelemetry shows where time goes inside a request across services and the database. Alerts fire on user-facing symptoms tied to SLOs — for example p95 latency over 500 ms or error rate over 1% for five minutes — rather than every CPU spike, and each alert links to a runbook.

    Practise this question and get feedback
  7. 7.

    How would you implement rate limiting for an API?

    IntermediateTechnical

    What the interviewer is evaluating

    Protecting services from abuse and overload.

    Key points a strong answer covers

    • Algorithms. Token bucket, fixed or sliding window.
    • Key. Limit per API key, user or IP.
    • Shared store. Store counters in Redis so limits work across instances.
    • Response. Return 429 with Retry-After and rate-limit headers.
    • Where. Enforce at the gateway/edge as well as in the app for sensitive endpoints.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Keeping counters in each instance's memory behind a load balancer.
    • Returning 500 instead of 429.

    Likely follow-up questions

    • How does a token bucket allow short bursts?
    • What extra limits would you put on a login endpoint?
    Example strong answer

    I'd identify clients by API key or user id, falling back to IP for anonymous traffic, and pick an algorithm — a token bucket is a good default because it allows short bursts while enforcing an average rate; a sliding window is simpler to explain. Counters live in Redis, often with an atomic Lua script, so the limit holds across all instances. Over the limit, the API returns 429 Too Many Requests with a Retry-After header and the usual rate-limit headers so clients can back off. Coarse limits belong at the edge — the API gateway or CDN — and stricter, specific limits go on sensitive endpoints like login and password reset.

    Practise this question and get feedback
  8. 8.

    How do you evolve an API without breaking existing clients?

    IntermediateTechnical

    What the interviewer is evaluating

    Backward compatibility discipline.

    Key points a strong answer covers

    • Additive changes. Prefer additive, backward-compatible changes.
    • Versioning. Version breaking changes (URL or header).
    • Deprecation. Deprecate with notice, headers and a timeline.
    • Contracts / monitoring. Document with OpenAPI, test contracts and monitor who still uses old versions.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Renaming fields in place.
    • Removing a version without checking usage.

    Likely follow-up questions

    • Is adding a new enum value a breaking change?
    • What are consumer-driven contract tests?
    Example strong answer

    Most changes can be additive: new optional fields, new endpoints, new optional parameters — clients ignore what they don't know. I avoid renaming or removing fields and changing types or meanings in place. When a breaking change is unavoidable, I introduce a new version — /v2/ in the URL or a version header — and run both side by side. The old version is deprecated with clear notice, Deprecation and Sunset headers, a migration guide and a timeline, and I monitor usage so I know who still calls it before removing it. An OpenAPI spec and contract tests catch accidental breaking changes in CI. Even adding an enum value can break strict clients, so I document how clients should treat unknown values.

    Practise this question and get feedback
  9. 9.

    How do you keep data consistent when one operation updates several services?

    AdvancedTechnical

    What the interviewer is evaluating

    Distributed transactions and practical patterns.

    Key points a strong answer covers

    • No distributed ACID. Two-phase commit is rarely practical across services.
    • Saga. A saga runs local transactions with compensating actions on failure.
    • Outbox. The transactional outbox writes the event in the same DB transaction as the change.
    • Idempotency / eventual consistency. Consumers are idempotent; the system is eventually consistent.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Writing to the DB and publishing to a queue as two separate steps.
    • Ignoring partial failures.

    Likely follow-up questions

    • What goes wrong if you save the order and then publish the event separately?
    • Choreography or orchestration for sagas?
    Example strong answer

    Across services you can't rely on one ACID transaction, and two-phase commit is usually too fragile and slow. Instead I use a saga: each service performs a local transaction and emits an event, and if a later step fails, earlier steps are undone with compensating actions — for an order, payment is refunded and stock released. To avoid the classic bug of saving the order but crashing before publishing the event, I use the transactional outbox: the event is written to an outbox table in the same database transaction as the order, and a relay publishes it. Consumers are idempotent because events can arrive twice, and the business accepts eventual consistency, with the UI showing states like 'payment pending'.

    Practise this question and get feedback
  10. 10.

    How would you design file uploads for large files (for example, videos)?

    IntermediateTechnical

    What the interviewer is evaluating

    Practical design for heavy payloads.

    Key points a strong answer covers

    • Direct to object storage. Store files in object storage, not the database or app server.
    • Pre-signed URLs. Clients upload directly with pre-signed URLs, bypassing your servers.
    • Multipart / resumable. Multipart or resumable uploads for large files.
    • Validation & security. Validate size and type, and scan files.
    • Processing. Process asynchronously (transcoding, thumbnails) via events.

    Suggested answer structure

    1. Define it in one sentence.
    2. Explain how it works underneath.
    3. Give a practical example from code or a project.
    4. Close with a trade-off, pitfall or when you'd use it.

    Common mistakes

    • Streaming gigabytes through the API server.
    • Trusting the file extension.

    Likely follow-up questions

    • How does a pre-signed URL stay secure?
    • How would you show upload progress and resume after a dropped connection?
    Example strong answer

    I wouldn't stream large files through the API servers. The client asks the API for permission, the API validates the user, size and type and returns pre-signed URLs, and the browser uploads directly to object storage like S3. For large videos I'd use multipart upload so chunks upload in parallel and a dropped connection only retries one chunk, with progress shown per part. When the upload completes, storage emits an event that triggers background jobs: verify the real file type, virus-scan, then transcode and generate thumbnails. The database stores metadata and the object key, never the file itself, and files are served through a CDN.

    Practise this question and get feedback

Behavioural & HR questions you'll also get

These come up in almost every full stack developer interview. Story questions are best answered with STAR — Situation, Task, Action, Result.

  • Tell me about yourself.

    BeginnerHR

    What the interviewer is evaluating

    Whether you can give a concise, relevant pitch that frames your experience around this job.

    Key points a strong answer covers

    • Present. Start with your current role and what you do.
    • Relevant past. Pick the most relevant past experience.
    • Strength / achievement. Include one strength or achievement with evidence.
    • Why this role. Finish with why this role is the next step.

    Suggested answer structure

    1. Present — your current role in one or two sentences.
    2. Past — the experience most relevant to this job.
    3. Proof — one achievement or strength with evidence.
    4. Future — why this role is the logical next step.

    Common mistakes

    • Reciting your whole CV chronologically.
    • Personal life story unrelated to the job.
    • Going over two minutes.

    Likely follow-up questions

    • Why are you looking to leave your current role?
    • What would your manager say is your biggest strength?
    Example strong answer

    I'm a front-end developer with four years' experience, currently at a fintech start-up where I build the customer dashboard in React and TypeScript. Before that I spent two years at an agency building e-commerce sites, which taught me to work fast with lots of different clients. The thing I'm proudest of recently is leading our move to a shared component library, which cut the time to build new screens by about a third. I'm now looking for a role where I can work on a larger product with a strong design system, which is exactly what drew me to this position.

  • Why should we hire you?

    BeginnerHR

    What the interviewer is evaluating

    Whether you understand the role and can match your strengths to its needs with evidence.

    Key points a strong answer covers

    • Role's needs. Show you understand what the role needs.
    • Matching strengths. Match two or three strengths to those needs.
    • Evidence. Back each with evidence.
    • Enthusiasm. Close with genuine enthusiasm.

    Suggested answer structure

    1. Name the two or three things the role needs most.
    2. Match each with your experience and evidence.
    3. Add what makes you different.
    4. Finish with genuine interest.

    Common mistakes

    • Generic claims like 'I'm hardworking' with no evidence.
    • Comparing yourself to other candidates you don't know.

    Likely follow-up questions

    • What would you do in your first 90 days?
    • What's one area where you'd need support?
    Example strong answer

    From the job description and our conversation, you need someone who can take ownership of the customer onboarding process, work with sales and product, and improve the numbers. I've done exactly that for three years: at my current company I redesigned onboarding for new accounts and cut the time to first value from 14 days to 6. I'm comfortable working across teams — I run a weekly session with sales and product on customer feedback — and I'm very data-driven, so I'd measure everything from day one. I'm also genuinely excited about your product, because it solves a problem I've seen customers struggle with.

  • Tell me about a time you disagreed with a teammate. How did you handle it?

    BeginnerBehavioural

    What the interviewer is evaluating

    Handling conflict constructively and keeping relationships.

    Key points a strong answer covers

    • Listened to their view. Show you listened to understand their view.
    • Used facts / common goal. Bring it back to facts or a shared goal.
    • Resolution & relationship. Resolve it and keep the relationship.

    Suggested answer structure

    1. Situation — one or two sentences of context.
    2. Task — what you were responsible for.
    3. Action — what you did, step by step (say “I”).
    4. Result — what changed, with a number if you can back it up.
    5. Reflection — what you learned or would do differently.

    Common mistakes

    • Making the other person the villain.
    • A story where you were simply right and they gave in.

    Likely follow-up questions

    • What if you couldn't reach agreement?
    • Have you ever been wrong in a disagreement?
    Example strong answer (a fictional story — use your own)

    On a website rebuild, a senior designer wanted an animated, image-heavy homepage, and I was worried it would hurt mobile load times and SEO. As the developer responsible for performance, I needed us to agree before the sprint started. I asked her to walk me through what she was trying to achieve — she wanted the brand to feel premium. I built two quick prototypes, one with her full design and one with lighter animations, and we tested both on a mid-range phone together. Hers took nearly six seconds to load. We agreed on a version that kept the key animation but lazy-loaded the rest. The page launched loading in under two seconds, and she later asked me to review designs earlier. I learned that testing together beats debating.

  • Tell me about a mistake you made and what you learned.

    BeginnerBehavioural

    What the interviewer is evaluating

    Honesty, accountability and learning.

    Key points a strong answer covers

    • Real mistake owned. Own a real mistake.
    • Fixed it. Show how you fixed it and who you told.
    • Changed behaviour. Show what you changed afterwards.

    Suggested answer structure

    1. Situation — one or two sentences of context.
    2. Task — what you were responsible for.
    3. Action — what you did, step by step (say “I”).
    4. Result — what changed, with a number if you can back it up.
    5. Reflection — what you learned or would do differently.

    Common mistakes

    • Choosing a fake mistake like 'I work too hard'.
    • Blaming others.

    Likely follow-up questions

    • How did your manager react?
    • How do you know you haven't repeated it?
    Example strong answer (a fictional story — use your own)

    In my first year as a marketing coordinator, I sent a promotional email to our whole list with the wrong discount code — I'd tested the email but not clicked the code itself. Within an hour customers were complaining that it didn't work. I told my manager immediately, set the wrong code to apply the discount too, and sent a short correction email with an apology. We lost very little revenue, and some customers replied thanking us for the quick fix. Since then I use a pre-send checklist that includes testing every link and code as a customer would, and I asked for a second person to check any campaign to more than 10,000 people.

  • Describe a situation where you worked under pressure or to a tight deadline.

    BeginnerBehavioural

    What the interviewer is evaluating

    Prioritisation, composure and delivery.

    Key points a strong answer covers

    • The pressure. Make the pressure concrete.
    • Prioritised. Show how you prioritised.
    • Communicated. Show how you kept people informed.
    • Delivered. Show the outcome.

    Suggested answer structure

    1. Situation — one or two sentences of context.
    2. Task — what you were responsible for.
    3. Action — what you did, step by step (say “I”).
    4. Result — what changed, with a number if you can back it up.
    5. Reflection — what you learned or would do differently.

    Common mistakes

    • Glorifying working all night as the solution.
    • No mention of prioritising.

    Likely follow-up questions

    • What would you do if it was clear you couldn't make the deadline?
    • How do you stop pressure affecting quality?
    Example strong answer (a fictional story — use your own)

    Two days before a client presentation, our analyst fell ill and I had to finish the market research report she'd been leading. I listed everything left and asked the account director which sections the client cared about most — pricing and competitor comparison. I focused on those, reused verified data from our previous report, and moved the appendix to a follow-up email. I sent a short update each evening so nobody was surprised. We delivered the core report on time, the client approved the next phase, and the appendix followed two days later. I learned to ask early what matters most rather than trying to do everything equally well.

  • What would you do if you realised you were going to miss a deadline?

    BeginnerSituational

    What the interviewer is evaluating

    Transparency and problem solving.

    Key points a strong answer covers

    • Tell people early. Flag it as soon as you know.
    • Assess the gap. Work out how far off you are.
    • Options. Offer options: reduced scope, help, a new date.
    • Prevent repeats. Learn why it happened.

    Suggested answer structure

    1. Clarify the situation and what's at stake.
    2. Say what you'd do first, and why.
    3. Explain who you'd involve and how you'd communicate.
    4. Describe how you'd check the outcome and prevent a repeat.

    Common mistakes

    • Waiting until the deadline to say anything.
    • Promising you'll just work all night.

    Likely follow-up questions

    • What if your manager is unavailable?
    • Has this happened to you?
    Example strong answer

    I'd tell the person depending on it as soon as I realised, not at the deadline. Before that conversation I'd work out how far off I am and why, so I could offer options: delivering the most important part on time and the rest a few days later, getting help from a colleague, or agreeing a new date. Then I'd let them decide what works best for them, and keep them updated. Afterwards I'd look at why it slipped — usually underestimating something — so I plan better next time.

Ready to answer them out loud?

Run a timed full stack developer mock interview, type or speak your answers, and get a score breakdown with what to improve.

Interview questions for related roles