The time command allows the user to view and edit the computer’s time.
Availability
Time is an internal command that is available in the following Microsoft operating systems.
Availability
Time syntax
Time examples
All Versions of MS-DOS
Windows 95
Windows 98
Windows ME
Windows NT
Windows 2000
Windows XP
Windows Vista
Windows 7
Windows 8
Windows 10
Windows 11
Time syntax
Windows Vista and later syntax
TIME [/T | time]
Type TIME with no parameters to display the current time setting and a prompt for a new time. Press Enter to keep the same time.
- Windows Vista and later syntax
- Windows XP and earlier syntax
If Command Extensions are enabled, the TIME command supports the /T switch which tells the command to only output the current time without prompting for a new time.
Windows XP and earlier syntax
TIME [time]
Time examples
time
Typing “time” alone displays the current time and give you the option to enter a new time.
time 12:00
Set the computer time to 12:00.
Pressing Enter without entering a new time keeps the current time.
Related information
- See our time definition for further information and related links on this term.