Customize Default Error Message on the Okta Login Form
Last Updated:
Overview
This article clarifies whether it is possible to customize the default error message displayed on the Okta login form. The user might see the following generic error message during a failed sign-in attempt:
Unable to sign in
Applies To
- Okta Sign-In Widget
- Login form customization
- Okta Identity Engine (OIE)
Solution
It is possible to customize the default error message. The generic error maps to the errors.E0000004 key in the backend. Override this key in the widget configuration to change the text.
- Log in to the Okta Admin Console.
- In the left-hand menu, go to Customizations > Brands.
- Select the brand to be modified.
- Go to the Pages tab.
- Locate the Sign-in page section and click Configure (or Edit).
- Add the following code snippet within the
{{{OktaUtil}}}object to customize the text:var config = OktaUtil.getSignInWidgetConfig(); if (config.i18n.en){ config.i18n.en['errors.E0000004'] = 'Custom Text'; }
