Topic Page

REST and HTTP interview questions and answers.

REST and HTTP questions are common in Java backend interviews because nearly every service exposes APIs. This page groups the API design and protocol fundamentals that help candidates explain not just how to build endpoints, but how to make them predictable, robust, and production-friendly.

What strong REST answers usually include

Interviewers often use API questions to measure clarity of thinking. Good answers show that you understand HTTP semantics, not just controller annotations. That includes choosing the right method, status code, and payload shape, as well as handling idempotency, caching, pagination, versioning, and error contracts consistently.

These questions also connect nicely with Spring Boot, transactions, and security. A strong API designer can explain what the endpoint should do, how clients should interact with it, and what guarantees or failure modes the contract exposes.

Representative REST and HTTP interview questions

  1. What is REST and what are its core constraints?
  2. What is the difference between PUT and PATCH?
  3. What does idempotency mean in HTTP?
  4. Which HTTP status codes matter most for backend APIs?
  5. How should you design error responses?
  6. How do pagination and filtering usually work in REST APIs?
  7. What is content negotiation?
  8. How does HTTP caching work with headers such as Cache-Control and ETag?
  9. How should API versioning be handled?
  10. What is the difference between authentication and authorization in API design?

Related pages