HTTP status codes indicate the result of a request. 2xx means success, 4xx means client error, 5xx means server error. They're like traffic lights—green means go, red means stop. Using correct codes helps API consumers handle responses properly.
Active Recall
2 Flashcards
Interview Flashcards & Mock Mode
Practice with 3D flip cards, voice reader, and timed interview simulations.
Speed Drills
60s Micro-Tests
CodeShot.in — Daily Challenges
60-second in-browser coding micro-challenges to sharpen syntax and problem-solving speed.
What are HTTP status codes and why are they important in REST APIs?
What is the difference between 401 and 403?
401 Unauthorized means the user is not authenticated—they need to log in. 403 Forbidden means they are authenticated but don't have permission. Think of 401 as 'Who are you?' and 403 as 'I know who you are, but you can't enter.'