IF you do not want the time zone offset to be enabled, you can use Date.UTC
Note. If Date is called as a constructor with more than one argument, the specified arguments represent local time. If UTC is desirable to use a new date (Date.UTC (...)) with the same arguments.
~ MDN
Exiting the Firefox dev console:
> new Date(2015,9,1) Date 2015-09-30T22:00:00.000Z
However, 00:00:00 GMT+0200 and 22:00:00.000Z are just different ways to represent the timeline offset in the Date string view. The difference lies in the method used when printing to the console: most browsers use .toString() , while Firefox uses .toISOString() . (Edited, it was previously indicated that the implementation of the toString method is different from the true one).
The Chrome ( Thu Oct 01 2015 00:00:00 GMT+0200 ) and Firefox ( Date 2015-09-30T22:00:00.000Z ) Date 2015-09-30T22:00:00.000Z , such as .getDate() and .getMonth() , return the same values ( 1 and 9 respectively). Date objects are the same.
source share