Login Page Modification – Redirect to SSO for End Users

PradeepReddyA
Tera Contributor

Overview

This article describes the configuration that ensures end users are redirected to the SSO Login Page after signing out from the Employee Center, instead of the standard username/password login page.

 

Requirement:

When an end user signs in to the Employee Center and then logs out:

  • They should be redirected to the SSO login page.
  • When clicking a notification link from a new browser profile, the user should be redirected to the standard login page (default ServiceNow behaviour).

PradeepReddyA_0-1766510465252.png

 

Current Behaviour:

By default, when an end user logs out, the system redirects them to the standard login page that requires entering a username and password.

      

PradeepReddyA_1-1766510465257.png

 

Implementation Details:

To achieve the required redirection behaviour, the standard Login widget was cloned, and separate widget instances were configured on the Login page. The cloned widget was modified to support external login mode (SSO). A fallback instance was retained to ensure quick rollback if needed.

Configuration Steps

  1. Clone the Login Widget
  2. Navigate to All → Service Portal → Widgets.
  3. Search for the Login widget under the Name column.
  4. Open the widget record.
  5. Click Clone Widget.
  6. Provide a Name and ID for the cloned widget (e.g., Copy of Login) and save the record.
  7. Update the Login Page Instances
  8. Navigate to All → Service Portal → Pages.
  9. Search for Login under the Title column.
  10. Open the Login page record.
  11. Under Page Content, verify that two widget instances are available.

Instance Configuration

  • Instance 1 – Original Widget
    • Set Active = false
    • Ensure the widget selected is Login
  • Instance 2 – Cloned Widget
    • Set Active = true
    • Under Widgets, replace the existing widget with Copy of Login.
  1. Modify the Cloned Widget
  2. Open the cloned widget (Copy of Login).
  3. Navigate to the Client Controller section.
  4. Add the following line of code:

c.externalLoginMode = true;

This sets the login widget to external login mode, triggering SSO redirection after logout.

0 REPLIES 0