Skip to page contentSkip to chat
ServiceNow support
    • Community
      Ask questions, give advice, and connect with fellow ServiceNow professionals.
      Developer
      Build, test, and deploy applications
      Documentation
      Find detailed information about ServiceNow products, apps, features, and releases.
      Impact
      Accelerate ROI and amplify your expertise.
      Learning
      Build skills with instructor-led and online training.
      Partner
      Grow your business with promotions, news, and marketing tools
      ServiceNow
      Learn about ServiceNow products & solutions.
      Store
      Download certified apps and integrations that complement ServiceNow.
      Support
      Manage your instances, access self-help, and get technical support.
Best practices – UI Actions - Support and Troubleshooting
  • >
  • Knowledge Base
  • >
  • Support and Troubleshooting (Knowledge Base)
  • >
  • Best practices – UI Actions
KB0546781

Best practices – UI Actions


13006 Views Last updated : Jan 30, 2025 public Copy Permalink English (Original)
  • English (Original)
  • Japanese
KB Summary by Now Assist

Issue

This document explains the best practices for creating/using UI actions.

UI actions simplify processes and guide user activity on forms and lists. Creating well-designed UI actions requires thinking through the function from a user perspective and applying a few guidelines. This article discusses best practices when designing and implementing UI actions.

Release

  All Releases

Resolution

  

Best practices video

Best Practice #1: Create well-designed UI actions

Create well-designed UI actions that are easy to find and use:

  • Use defaults to reflect the most likely or safest user choice. Ensure that primary and secondary actions are appropriately placed to indicate their relative importance.
  • Ensure that the appearance and function of UI actions are consistent throughout the platform.

Best Practice #2: Give each UI action a distinct action name.

When creating UI actions, give each a distinct name. A good action name helps to organize the actions and is easy to distinguish from other actions.

Best Practice #3: Use conditions in UI actions.

Use conditions in UI actions to specify under what circumstances they should execute. 

Best Practice #4: Use buttons, menus, and links appropriately in forms and lists.

For forms and lists, use buttons, menus, and links appropriately:

  • Use buttons for frequently used actions, and avoid cluttering forms with too many buttons (four or five should be the maximum). Use short, clear button names (max. 25 characters). Long names can cause the buttons to wrap to multiple lines and result in layout inconsistencies among forms.
  • Use links to avoid too many buttons or button names that are too long.
  • Use menus for UI actions that are not used as frequently as actions on buttons. For example, put options related to the record or form administrative functions on the form context menu.

Best Practice #5: Leverage business rules.

Leverage business rules to avoid putting all necessary logic into UI actions. Do minimal work in the UI action, and let business rules react to it. Not only does this make it easier to debug the UI action and the business rule, but it also makes the logic available elsewhere in the system by calling the business rule.

Best Practice #6: Leverage script includes.

Leverage script includes if the logic exists in more than one place, or if it is fairly complex or specialized. Script includes make code more scalable, testable, and manageable. 

Related Links

More about UI Actions:

  • Community Live Stream - Behind the Answers - UI Actions

The world works with ServiceNow.

Sign in for more! There's more content available only to authenticated users Sign in for more!
Did this KB article help you?
Did this KB article help you?

How would you rate your Now Support digital experience?

*

Very unsatisfied

Unsatisfied

Neutral

Satisfied

Very satisfied

Very unsatisfied

Unsatisfied

Neutral

Satisfied

Very satisfied

What can we improve? Please select all that apply.

What are we doing well? Please select all that apply.

Tell us more

*

Do you expect a response from this feedback?

  • Terms and conditions
  • Privacy statement
  • GDPR
  • Cookie policy
  • © 2025 ServiceNow. All rights reserved.