What is the difference between 401 and 403?

REST API design and errors · Freshers

Model answer

401 means the request has no valid authentication: you need to sign in. 403 means the server knows who you are but you are not allowed to do this. Mixing them up confuses clients and monitoring.

Learn this topic

Build a REST API: Create, Read, Update and Delete Tasks in the course Node.js and Express: Build a Back End API from Scratch.

Sign in to add your own answer.

More questions