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.
Issues with Date\Time picker on service portal - getting message javascript error "zone.offset has been deprecated in favor of zone.utcOffset"? - Support and Troubleshooting
  • >
  • Knowledge Base
  • >
  • Support and Troubleshooting (Knowledge Base)
  • >
  • Issues with Date\Time picker on service portal - getting message javascript error "zone.offset has been deprecated in favor of zone.utcOffset"?
KB0714485

Issues with Date\Time picker on service portal - getting message javascript error "zone.offset has been deprecated in favor of zone.utcOffset"?


1842 Views Last updated : Apr 7, 2024 public Copy Permalink
KB Summary by Now Assist

Issue

Symptoms


While using date picker with the date / date time fields on service portal, getting below javascript error,

moment-timezone-with-data.js:476 zone.offset has been deprecated in favor of zone.utcOffset

Complete error stack is shown in below screenshot,

Release


Any supported release. 

Cause


Older version of moment.js third party library (/ajax/libs/moment.js/2.22.2/moment.min.js) was included in the out of the box provided "moment.js" widget dependency (https://InstanceName.service-now.com/nav_to.do?uri=sp_dependency.do?sys_id=db6689c1cb11120000f8d856634c9c3b).

Hence system loads the older version of moment.js in DOM and eventually we get the error "zone.offset has been deprecated in favor of zone.utcOffset" while accessing date /date time field since older version of moment.js library has deprecated methods.

Resolution


Out of the box provided moment.js widget dependency has following definition,

Name = moment
Application = Global
Included on Page load = false

JS Includes,
order = 200, JS Include = /scripts/thirdparty/moment-timezone-0.4.0/moment-timezone-utils.js, JS file URL = /scripts/thirdparty/moment-timezone-0.4.0/moment-timezone-utils.js

order = 200, JS Include = /scripts/thirdparty/moment-jdateformatparser-1.0.2/moment-jdateformatparser.js, JS file URL = /scripts/thirdparty/moment-jdateformatparser-1.0.2/moment-jdateformatparser.js


Hence, we recommend, updating your "moment.js" widget dependency as per the out of the box definition 

OR

Keep the out of the box provided version and delete the custom moment.js widget dependency.

Additional Information


Create a Widget dependency

Moment.js community thread


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.