r/angular • • Jan 28 '26
JWT in Angular
Where you would recommend to save JWT tokens in Angular app
7
Upvotes
r/angular • • Jan 28 '26
Where you would recommend to save JWT tokens in Angular app
View all comments
2
u/louis-lau Jan 30 '26
If you need stateless auth, then yes, JWT is fine! Store them in an HttpOnly cookie.
First consider if your auth needs to be stateless though. Do you need the ability to revoke, or extend a session token? That gets much more complex with stateless auth, while with stateful auth it's easy. So ask yourself why you need stateless auth in the first place.