Skip to main content

2. Backend config

1) Install supertokens package#

npm i supertokens-node

2) Create a configuration file (config/supertokensConfig.js)#

  • Create a config folder in the root directory of your project.
  • Create a supertokensConfig.js inside the config folder.
  • An example of this file can be found here.

3) Create a backend config function#

Please fill the form below to see the code snippet (* = Required)
To learn more about what these properties mean read here.
Your app's name:*
This is the name of your application
API Domain:*
This is the URL of your app's API server.
API Base Path:
SuperTokens will expose it's APIs scoped by this base API path.
Website Domain:*
This is the URL of your website.
Website Base Path:
SuperTokens UI will be shown on this website route.
Submit form