Render a custom error page

Hi, I am just trying to render a customer error page as per the documentation here but it doesn’t seem to be working for me. I am always redirected to http://localhost:3000/callback

Below is the management API call that I used to update the custom error page html,

  curl --request PATCH \
  --url '' \
  --header 'authorization: Bearer mytoken' \
  --header 'content-type: application/json' \
  --data '{"error_page": {"html": "This is the error page", "show_log_link": false, "url": ""}}'

API call returns 200 OK but the custom error page never displays.

To test this, I have added a custom built action in the Post Login flow that does api.access.deny(“Test error.”);

Any assistance on what I am doing wrong here would be greatly appreciated.


1 Like

Hi @blakshi

Welcome to the Auth0 Community.

If your callback url is valid then the current behaviour is expected as per this doc, the error will be received as a query param on your callback url, your application can then parse for these errors and respond appropriately.

The custom error page can potentially replace the default Auth0 error page which will be used if the callback url is not valid or:

  • Required parameters are missing when calling the Auth0 Authentication API Login endpoint.
  • User opens an expired password reset link (when using the Classic Universal Login Experience).
  • User navigates to a bookmarked login page and a Default Login Route is not specified.

Above taken from our doc here

Warm regards.

1 Like