What time zone does the JavaScript new Date() use?

JavaScript will use the client's local time but it also has UTC / GMT methods. The following is from Mozilla:

The JavaScript Date object supports a number of UTC (universal) methods, as well as local time methods. UTC, also known as Greenwich Mean Time (GMT), refers to the time as set by the World Time Standard. The local time is the time known to the computer where JavaScript is executed.

While methods are available to access date and time in both UTC and the localtime zone, the date and time are stored in the local time zone:

Note: It's important to keep in mind that the date and time is stored in the local time zone, and that the basic methods to fetch the date and time or its components all work in the local time zone as well.

Reference: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date


By default, JS will use your browser timezone, but if you want to change the display, you can for example use the toString() function ;)

var d1=new Date();
d1.toString('yyyy-MM-dd');       //returns "2015-03-27" in IE, but not FF or Chrome
d1.toString('dddd, MMMM ,yyyy')  //returns "Friday, March 27,2015" in IE, but not FF or Chrome