Configure Custom NTP Server in Windows Registry
This guide explains how to configure custom Network Time Protocol (NTP) servers in Windows using the Registry Editor (Regedit). By modifying specific registry keys, you can define custom time servers, adjust polling intervals, and ensure your system clock stays accurately synchronized with your preferred public or internal NTP sources.
Step 1: Open the Registry Editor
- Press Win + R to open the Run dialog box.
- Type
regeditand press Enter. - Click Yes if prompted by User Account Control (UAC).
Step 2: Configure the NTP Server List
To specify your custom NTP server addresses:
- Navigate to the following path:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Parameters - Locate the string value named NtpServer in the right pane.
- Double-click NtpServer to edit its value data.
- Enter the NTP server address followed by the flag
,0x1(for SpecialInterval) or,0x9(for SpecialInterval and fallback). For multiple servers, separate them with spaces.- Example:
pool.ntp.org,0x1 time.google.com,0x1
- Example:
- Click OK to save the changes.
Step 3: Set the Time Service Type
Ensure Windows is set to synchronize using NTP rather than domain hierarchy (NT5DS):
- In the same Parameters key, find the Type string value.
- Double-click Type and set its value to
NTP. - Click OK.
Step 4: Adjust the Polling Interval (Optional)
To define how frequently Windows synchronizes with the custom NTP server:
- Navigate to:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpClient - Locate and double-click the DWORD (32-bit) value named SpecialPollInterval.
- Switch the Base option to Decimal.
- Enter the interval duration in seconds (e.g.,
86400for 24 hours,3600for 1 hour). - Click OK.
Step 5: Restart the Windows Time Service
Apply the new registry settings by restarting the
W32Time service:
Press Win + X and select Terminal (Admin) or Command Prompt (Admin).
Stop the Windows Time service by running:
net stop w32timeStart the service again:
net start w32timeForce an immediate time synchronization:
w32tm /resyncVerify the current configuration and source by running:
w32tm /query /status