Changing the Timezone (Microsoft Windows)

To totally unlock this section you need to Log-in


Login

Timezone is a critical settings on client and server systems. This setting is a “computer-wide” setting, not a per-user setting, so we will not be able to set a specific timezone for a specific user, on Windows systems.

This setting allows us to set the time according to the geographical location the computer is located at. We can change the time zone of a computer in Date and Time properties window which can be opened by running timedate.cpl (Control Panel applet) from Run window.

Set Time, Date, and Timezone using GUI

On modern Windows operating systems the process is very simple: Right-click the time field in the lower right corner and then click the Adjust date/time option, like in the following image:

Changing the Timezone (Microsoft Windows)

In the Settings window, you can change the time, date, and timezones of each Windows Server. From this step the process to change date, time and timezone is quite self-explanatory.

Changing the Timezone (Microsoft Windows)

Another way to achieve this task is to open the time and date settings window by clicking, on Windows Server systems, on the corresponding field in the Local Server section of the Server Manager control panel.

Changing the Timezone (Microsoft Windows)

In this last case, this procedure will open the old management window through which you can set the time, date and time zone for the system.

Set time, date, and time zone using Command Prompt

Now that we have seen how to get and set time, date and time zone by using Windows GUI, it could be useful to know even how to get these info using Command Prompt commands. By typing the following command will open the time and date setting window, even in a Server Core installation:

control timedate.cpl

While, to every Windows system, to display the current date and time we could use the following commands:

Date /t
Time /t

Changing the Timezone (Microsoft Windows)

To set time and date, you can use the corresponding time and date commands at the command line.

Take note that the default output from DATE /T is in the United States is “1/23/1997” but this is dependent on the country/locale (and obviously in which language you have installed Windows on your system.

To set the time we will use a simple time HH:MM command.

For both date and time commands there are only two errorlevels, 0 (zero) if the command has been executed successfully and 1 (one) if the user has no administrative privileges to change these parameters.

At this point we will go back to our timezone parameter. This info is very critical on some production systems and this info should be modified only by administrative users and only after reviewing all the implications (databases, applications, servers, timestamps, etc.).

To easily manage this info (timezone) on Windows systems, from Windows Server 2012 and above, have been added the Timezone Utility (tzutil) tool that allows us to display and set a time zone through the Windows command line.

To use it, we first open the command line with administrator privileges and make sure we are in the System32 folder.

To display the current Windows Server Time Zone configured on the system, we type the following command:

tzutil /g

Changing the Timezone (Microsoft Windows)

To display all available time zones, we could type the following command:

tzutil /l

Changing the Timezone (Microsoft Windows)

The following list includes all timezone available using tzutil.exe program. On the left column you will see the

(UTC-12:00) International Date Line West
Dateline Standard Time

(UTC-11:00) Co-ordinated Universal Time-11
UTC-11

(UTC-10:00) Aleutian Islands
Aleutian Standard Time

(UTC-10:00) Hawaii
Hawaiian Standard Time

(UTC-09:30) Marquesas Islands
Marquesas Standard Time

(UTC-09:00) Alaska
Alaskan Standard Time

(UTC-09:00) Co-ordinated Universal Time-09
UTC-09

(UTC-08:00) Baja California
Pacific Standard Time (Mexico)

(UTC-08:00) Co-ordinated Universal Time-08
UTC-08

(UTC-08:00) Pacific Time (US & Canada)
Pacific Standard Time

(UTC-07:00) Arizona
US Mountain Standard Time

(UTC-07:00) Chihuahua, La Paz, Mazatlan
Mountain Standard Time (Mexico)

(UTC-07:00) Mountain Time (US & Canada)
Mountain Standard Time

(UTC-06:00) Central America
Central America Standard Time

(UTC-06:00) Central Time (US & Canada)
Central Standard Time

(UTC-06:00) Easter Island
Easter Island Standard Time

(UTC-06:00) Guadalajara, Mexico City, Monterrey
Central Standard Time (Mexico)

(UTC-06:00) Saskatchewan
Canada Central Standard Time

(UTC-05:00) Bogota, Lima, Quito, Rio Branco
SA Pacific Standard Time

(UTC-05:00) Chetumal
Eastern Standard Time (Mexico)

(UTC-05:00) Eastern Time (US & Canada)
Eastern Standard Time

(UTC-05:00) Haiti
Haiti Standard Time

(UTC-05:00) Havana
Cuba Standard Time

(UTC-05:00) Indiana (East)
US Eastern Standard Time

(UTC-05:00) Turks and Caicos
Turks And Caicos Standard Time

(UTC-04:00) Asuncion
Paraguay Standard Time

(UTC-04:00) Atlantic Time (Canada)
Atlantic Standard Time

(UTC-04:00) Caracas
Venezuela Standard Time

(UTC-04:00) Cuiaba
Central Brazilian Standard Time

(UTC-04:00) Georgetown, La Paz, Manaus, San Juan
SA Western Standard Time

(UTC-04:00) Santiago
Pacific SA Standard Time

(UTC-03:30) Newfoundland
Newfoundland Standard Time

(UTC-03:00) Araguaina
Tocantins Standard Time

(UTC-03:00) Brasilia
E. South America Standard Time

(UTC-03:00) Cayenne, Fortaleza
SA Eastern Standard Time

(UTC-03:00) City of Buenos Aires
Argentina Standard Time

(UTC-03:00) Greenland
Greenland Standard Time

(UTC-03:00) Montevideo
Montevideo Standard Time

(UTC-03:00) Punta Arenas
Magallanes Standard Time

(UTC-03:00) Saint Pierre and Miquelon
Saint Pierre Standard Time

(UTC-03:00) Salvador
Bahia Standard Time

(UTC-02:00) Co-ordinated Universal Time-02
UTC-02

(UTC-01:00) Azores
Azores Standard Time

(UTC-01:00) Cabo Verde Is.
Cape Verde Standard Time

(UTC) Co-ordinated Universal Time
UTC

(UTC+00:00) Casablanca
Morocco Standard Time

(UTC+00:00) Dublin, Edinburgh, Lisbon, London
GMT Standard Time

(UTC+00:00) Monrovia, Reykjavik
Greenwich Standard Time

(UTC+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna
W. Europe Standard Time

(UTC+01:00) Belgrade, Bratislava, Budapest, Ljubljana, Prague
Central Europe Standard Time

(UTC+01:00) Brussels, Copenhagen, Madrid, Paris
Romance Standard Time

(UTC+01:00) Sao Tome
Sao Tome Standard Time

(UTC+01:00) Sarajevo, Skopje, Warsaw, Zagreb
Central European Standard Time

(UTC+01:00) West Central Africa
W. Central Africa Standard Time

(UTC+02:00) Amman
Jordan Standard Time

(UTC+02:00) Athens, Bucharest
GTB Standard Time

(UTC+02:00) Beirut
Middle East Standard Time

(UTC+02:00) Cairo
Egypt Standard Time

(UTC+02:00) Chisinau
E. Europe Standard Time

(UTC+02:00) Damascus
Syria Standard Time

(UTC+02:00) Gaza, Hebron
West Bank Standard Time

(UTC+02:00) Harare, Pretoria
South Africa Standard Time

(UTC+02:00) Helsinki, Kyiv, Riga, Sofia, Tallinn, Vilnius
FLE Standard Time

(UTC+02:00) Jerusalem
Israel Standard Time

(UTC+02:00) Kaliningrad
Kaliningrad Standard Time

(UTC+02:00) Khartoum
Sudan Standard Time

(UTC+02:00) Tripoli
Libya Standard Time

(UTC+02:00) Windhoek
Namibia Standard Time

(UTC+03:00) Baghdad
Arabic Standard Time

(UTC+03:00) Istanbul
Turkey Standard Time

(UTC+03:00) Kuwait, Riyadh
Arab Standard Time

(UTC+03:00) Minsk
Belarus Standard Time

(UTC+03:00) Moscow, St. Petersburg, Volgograd
Russian Standard Time

(UTC+03:00) Nairobi
E. Africa Standard Time

(UTC+03:30) Tehran
Iran Standard Time

(UTC+04:00) Abu Dhabi, Muscat
Arabian Standard Time

(UTC+04:00) Astrakhan, Ulyanovsk
Astrakhan Standard Time

(UTC+04:00) Baku
Azerbaijan Standard Time

(UTC+04:00) Izhevsk, Samara
Russia Time Zone 3

(UTC+04:00) Port Louis
Mauritius Standard Time

(UTC+04:00) Saratov
Saratov Standard Time

(UTC+04:00) Tbilisi
Georgian Standard Time

(UTC+04:00) Yerevan
Caucasus Standard Time

(UTC+04:30) Kabul
Afghanistan Standard Time

(UTC+05:00) Ashgabat, Tashkent
West Asia Standard Time

(UTC+05:00) Ekaterinburg
Ekaterinburg Standard Time

(UTC+05:00) Islamabad, Karachi
Pakistan Standard Time

(UTC+05:30) Chennai, Kolkata, Mumbai, New Delhi
India Standard Time

(UTC+05:30) Sri Jayawardenepura
Sri Lanka Standard Time

(UTC+05:45) Kathmandu
Nepal Standard Time

(UTC+06:00) Astana
Central Asia Standard Time

(UTC+06:00) Dhaka
Bangladesh Standard Time

(UTC+06:00) Omsk
Omsk Standard Time

(UTC+06:30) Yangon (Rangoon)
Myanmar Standard Time

(UTC+07:00) Bangkok, Hanoi, Jakarta
SE Asia Standard Time

(UTC+07:00) Barnaul, Gorno-Altaysk
Altai Standard Time

(UTC+07:00) Hovd
W. Mongolia Standard Time

(UTC+07:00) Krasnoyarsk
North Asia Standard Time

(UTC+07:00) Novosibirsk
N. Central Asia Standard Time

(UTC+07:00) Tomsk
Tomsk Standard Time

(UTC+08:00) Beijing, Chongqing, Hong Kong SAR, Urumqi
China Standard Time

(UTC+08:00) Irkutsk
North Asia East Standard Time

(UTC+08:00) Kuala Lumpur, Singapore
Singapore Standard Time

(UTC+08:00) Perth
W. Australia Standard Time

(UTC+08:00) Taipei
Taipei Standard Time

(UTC+08:00) Ulaanbaatar
Ulaanbaatar Standard Time

(UTC+08:45) Eucla
Aus Central W. Standard Time

(UTC+09:00) Chita
Transbaikal Standard Time

(UTC+09:00) Osaka, Sapporo, Tokyo
Tokyo Standard Time

(UTC+09:00) Pyongyang
North Korea Standard Time

(UTC+09:00) Seoul
Korea Standard Time

(UTC+09:00) Yakutsk
Yakutsk Standard Time

(UTC+09:30) Adelaide
Cen. Australia Standard Time

(UTC+09:30) Darwin
AUS Central Standard Time

(UTC+10:00) Brisbane
E. Australia Standard Time

(UTC+10:00) Canberra, Melbourne, Sydney
AUS Eastern Standard Time

(UTC+10:00) Guam, Port Moresby
West Pacific Standard Time

(UTC+10:00) Hobart
Tasmania Standard Time

(UTC+10:00) Vladivostok
Vladivostok Standard Time

(UTC+10:30) Lord Howe Island
Lord Howe Standard Time

(UTC+11:00) Bougainville Island
Bougainville Standard Time

(UTC+11:00) Chokurdakh
Russia Time Zone 10

(UTC+11:00) Magadan
Magadan Standard Time

(UTC+11:00) Norfolk Island
Norfolk Standard Time

(UTC+11:00) Sakhalin
Sakhalin Standard Time

(UTC+11:00) Solomon Is., New Caledonia
Central Pacific Standard Time

(UTC+12:00) Anadyr, Petropavlovsk-Kamchatsky
Russia Time Zone 11

(UTC+12:00) Auckland, Wellington
New Zealand Standard Time

(UTC+12:00) Co-ordinated Universal Time+12
UTC+12

(UTC+12:00) Fiji
Fiji Standard Time

(UTC+12:45) Chatham Islands
Chatham Islands Standard Time

(UTC+13:00) Co-ordinated Universal Time+13
UTC+13

(UTC+13:00) Nuku’alofa
Tonga Standard Time

(UTC+13:00) Samoa
Samoa Standard Time

(UTC+14:00) Kiritimati Island
Line Islands Standard Time

If you want to quickly find all available time zones (for example, with a UTC -6 offset), run the command:

tzutil /l | find /I “utc-06”

Changing the Timezone (Microsoft Windows)

To change the current time zone in Windows Server and Windows Clients, type the following command, between the doubles, enter the timezone code (under each UTC definition) as it appears in the list of the previous command. For example, for the Greek time zone type:

tzutil /s “GTB Standard Time”

To confirm that the time zone has changed, you can see the corresponding registry entry by using the following command from within the same command-line window.

reg query HKLM\SYSTEM\CurrentControlSet\Control\TimeZoneInformation

NOTE: take note that to use the tzutil.exe program you will need to have administrative privileges.

Changing the Timezone (Microsoft Windows)

To disable Daylight Saving Time for a specific timezone, you must specify a time zone identifier with the suffix _dstoff, for example:

tzutil /s “Central European Standard Time_dstoff”

After executing this command, you will change the current time zone of the computer and disable the seasonal clock change.

Set time, date and time zone with Powershell

By using Powershell, on all modern Windows OSes, we can view the current date and time, type the following command:

Get-Date

Changing the Timezone (Microsoft Windows)

To set the time and date through Powershell the process is very easy. Use the following command as an example by changing the date and time values.

Set-Date -Date “06/06/2017 14:45”

Alternatively, you can simply type the Set-Date command and promptly you will be prompted to enter the server’s date and time:

Changing the Timezone (Microsoft Windows)

To view the current time zone through Powershell, type the following simple command:

[TimeZoneInfo]::Local

Or…

Get-TimeZone

Changing the Timezone (Microsoft Windows)

Before changing the time zone, you will need to know the right name (Timezone ID). Type the following command to see all available time zones in Windows Server and Windows Clients:

[System.TimeZoneInfo]::GetSystemTimeZones()

Or…

Get-TimeZone -ListAvailable

Changing the Timezone (Microsoft Windows)

To change the time zone, use the following command along with the corresponding time zone of your server or client:

Set-TimeZone -Name “GTB Standard Time”

Allow or Prevent Users from Changing the Time Zone

By default, a user doesn’t need the administrator permissions to change the time zone (unlike changing date/time). This behavior can be changed using Local Security Settings console (secpol.msc).

Go to Security Settings -> Local Policy -> User Rights Assignment. The policy is called Change the time zone. As you can see, time zone can be changed by the system itself, administrators and all users. To prevent users from changing the time zone, remove Users group from the list of accounts in this policy.

Changing the Timezone (Microsoft Windows)

Change the TimeZone in Windows XP from Command Prompt

A quick way to change timezone on an old Windows XP system is the following command executed in a Command Prompt:

RunDLL32.exe shell32.dll,Control_RunDLL timedate.cpl,,/Z “Central Standard Time”

In Windows the information about the value of the current time zone is stored in the registry key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation.

Changing the Timezone (Microsoft Windows)

For example, in our case you can see that Romance Daylight Time is currently used. The same information can be obtained with the following query:

reg query HKLM\SYSTEM\CurrentControlSet\Control\TimeZoneInformation

Changing the Timezone (Microsoft Windows)

The list of available time zones in Windows XP / Windows Server 2003 is stored in the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Time Zones.

Changing the Timezone (Microsoft Windows)

To change the current time zone to Central America Standard Time (GMT-06:00 – Central America), use the command:

RunDLL32.exe shell32.dll,Control_RunDLL timedate.cpl,,/Z Central America Standard Time

Or:

Control.exe TIMEDATE.CPL,,/Z Central America Standard Time

Make sure that the time zone has been changed:

reg query HKLM\SYSTEM\CurrentControlSet\Control\TimeZoneInformation

Changing the Timezone (Microsoft Windows)

Script to Change the TimeZone Using GPO

Another approach to change the time zone on multiple systems using a GPO and a script is the following PowerShell script that allows to change the time zone on any computer, assuming that Windows XP / Windows Server 2003 computers still exist in your network).

This script can be assigned using group policies to all domain computers or a certain organizational units (OU). The script determines the OS version, and if it is Windows Vista or later, it uses tzutil.exe to change the time zone. The $timeZone variable will contain the time zone ID we want to assign to all system under the GPO.

In the other case the time zone is changed using RunDLL32.exe (Windows XP).

$timeZone = “Central Europe Daylight Time”
$WinOSVerReg = Get-Item “HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion”
$WinOSVer = $WinOSVerReg.GetValue(“CurrentVersion”)
if ($WinOSVer -GE 6){
tzutil.exe /s $timeZone
} Else {
$params = “/c Start `”Change timeZone`” /MIN %WINDIR%\System32\Control.exe TIMEDATE.CPL,,/Z ”
$params += $timeZone
$proc = [System.Diagnostics.Process]::Start( “CMD.exe”, $params )
}