How to Redirect Users to a Specific URL Based on the HTTP Status Code
Last Updated:
Overview
Applies To
- Okta Access Gateway
Solution
- Edit the application and go to the policy section.
- Edit root policy and click on the Advanced tab.
- Add the following directive in the advanced section:
proxy_intercept_errors on; error_page 404 502 503 504 https://okta.com;The above policy will send the users to https://okta.com whenever an HTTP 404, 502, 503, or 504 error is received by the backend application or the application is unresponsive. - Click on Not Validated to validate the setting and save the application.
