Skip to content
Welcome to the new, Chris Portfolio! đź‘‹
Projects
AWS Cognito

AWS Cognito with Node.js

Cognito is a user management service by Amazon Web Services. It is a very interesting option for those who wish to quickly focus on coding your app instead of having to set up the boring sign-up/authentication flow and all that comes with user management, like password recovery. Besides it, Cognito is free to up to 50 000 active users, which is great for starting businesses. It works by grouping users the way your business need, giving them roles, enforcing minimum password strength, two-factor authentication (2FA), and finally returning three tokens (two of them are the well-known JWT). The best thing about is it supports all major web platforms and mobile. SDKs are available for Obj-C, java, and Swift as well.

I aim to give you an overview of what AWS Cognito solves and how to set Cognito User Pools, and how to use it for user login, signup, MFA, forgot password, change password, logout, and how to use it as your app’s authentication provider, as well as explain how to use the concepts of Id, Access, and Refresh Tokens.

I will also explain a problem we worked on and take a look at the library used (amazon-cognito-identity-js (opens in a new tab)).