This guide refers to using SSO to authenticate access to your endpoints. You cannot use these instructions to set up SSO for logging into your ngrok account in the dashboard.
- Restrict access to your ngrok endpoints to only users authenticated via Okta
- Use Okta security policies, multi-factor authentication (MFA) authenticators such as Okta Verify, FastPass, and FIDO2, and ThreatInsights to control access to ngrok endpoints
- Use Okta’s Dashboard to facilitate access to ngrok apps
What you’ll need
- An Okta account with administrative rights to create apps.
- An ngrok Pay-as-you-go account with an authtoken or admin access to configure endpoints with OpenID Connect.
1. Configure Okta
Create an OpenID Connect app integration in Okta by following Okta’s guide to creating an app integration. When you configure the application, use these ngrok-specific values:- Sign-in redirect URI:
https://idp.ngrok.com/oauth2/callback - Login initiated by: Login initiated by app
https://acme.okta.com).
Assign the users and groups that need access to the application so those users can sign in through Okta.
To test the integration yourself, make sure you’re assigned to the app.
2. Configure ngrok
Use the OpenID Connect Traffic Policy action to enforce Okta authentication on your endpoint.This step assumes you have an app running locally (for example, on
localhost:3000) with the ngrok client installed.policy.yaml file with the following content, replacing the placeholder values with those copied from Okta:
YOUR_DOMAIN with your ngrok domain:
https://okta-sso-test.ngrok.app).
3. Test the integration
- In your browser, launch an incognito window.
- Access your ngrok endpoint (for example,
https://okta-sso-test.ngrok.appor using a copied URL). - When prompted, log in with your Okta credentials.
- After you log in, you see your web app.