- How to Find Your Windows 10 Build Number, Version, Edition and Bitness
- Find Windows 10 Build Number, Version, Edition and Bitness
- System Settings App
- System – Control Panel
- Using the DirectX Diagnostic Tool
- Using WMIC (WMI command-line tool)
- System Information Utility
- About Windows (WinVer)
- Watermark on the Desktop
- Using SystemInfo.exe Command-line tool
- Windows 10 Build/Version Upgrade History
- how to tell what version of windows and/or cmd.exe a batch file is running on?
- 8 Answers 8
- How to get Windows version from command prompt or from PowerShell
- 6 Answers 6
- What version of Windows do I have?
- Checking your Windows version using a keyboard shortcut
- Detect Windows Server version 32/64-bit in CLI
- 10 Answers 10
How to Find Your Windows 10 Build Number, Version, Edition and Bitness
The Build Number, Version, “Bit”ness (32-bit or 64-bit) of your Windows installation can be determined using many ways, and here are some of the methods listed. Screenshots are from a Windows 10 PC, but most of the information applies to all versions of Windows.
Find Windows 10 Build Number, Version, Edition and Bitness
System Settings App
In Windows 10, use the System Settings app to find the OS information. Click Start, type About your PC. Click About your PC from the results.
System – Control Panel
Press Winkey + Pause-break keys. This opens the Control Panel → All Control Panel Items → System. Alternately, you can run sysdm.cpl directly.
Note: Since the Windows 10 v20H2 update, the following interface is hidden. Pressing the Winkey + Pause-break would take you to the modern Settings page instead. Microsoft is gradually porting items from the classic Control Panel to the Settings user interface. However, you can access the classic System panel by running this shell command from the Run dialog.
Using the DirectX Diagnostic Tool
Using WMIC (WMI command-line tool)
Open a Command Prompt window and type:
The WMIC command-line (mentioning “OSArchitecture”) tells you the bitness of your Windows. You can get as many details as you need using WMIC OS Get command, such as:
Note: Here is a complete list of fields you can retrieve using WMIC OS Get (which uses the Win32_OperatingSystem class)
In addition to all of the above methods, you can check the Help → About page any Windows desktop application like Notepad, Wordpad, Internet Explorer or others, for the Windows version & build information.
Note: The following methods don’t tell you whether you have an x64 version of Windows installed or not. They only show the OS installed and the System or Processor type (x86 or x64). System Type x64 means the processor is 64-bit. But that does not necessarily mean you have Windows x64. It could be Windows x86 OS running on an x64 CPU based machine.
System Information Utility
The System Information utility (MSInfo32.exe) has the details you need.
Scroll down and check the Hardware Abstraction Layer field. It also shows the full build number, including the minor build number.
About Windows (WinVer)
Alternately, in Command Prompt, run the ver.exe command to know the OS build number.
Watermark on the Desktop
If you’ve added the PaintDesktopVersion or the DisplayVersion registry values as in article Display Build Info, Version and WinDir Path in the Desktop, you’ll see the Windows Edition, Build Information and WinDir path in the desktop shown as a watermark. For evaluation versions of Windows, the watermark displays by default.
Using SystemInfo.exe Command-line tool
Open a Command Prompt window and type in:
The SystemInfo command outputs more information than you need. To get the OS Name and OS Version fields from the output, type this in the Command Prompt window:
The findstr command will parse the output and display only the two lines (OS name and version.)
Windows 10 Build/Version Upgrade History
Did you know that Windows 10 keeps track of your every build/feature upgrade in the registry? Redditor u/sizzlr has found an interesting registry location and wrote a PowerShell script to unscramble the Windows 10 build installation dates from the registry.
Every time you install a feature update, Windows 10 creates a new subkey named “Source OS (Updated on )” and a bunch of values in the right pane. The registry key is located at:
Additionally, there are two values, namely InstallTime and InstallDate, which store the install date and time. The following PowerShell script gathers all the details for you and presents in a table:
Do you know any other methods to find the Windows build, OS version and bitness? Let’s know in the Comments section below.
how to tell what version of windows and/or cmd.exe a batch file is running on?
How can one determine what version of Windows and/or cmd.exe a batch file is running on?
There is no cmd /version that I’ve been able to find and the results of SET in a command prompt session don’t give anything obviously unique (between XP and Win7 anyway).
8 Answers 8
The version of cmd.exe should actually be pretty irrelevant, unless you try to use features that didn’t exist before (in command.com for example). There is the pseudovariable
which holds the version of the command extensions which has been 2 for ages (at least back to NT 4, iirc).
But, back to the point: Running ver and parsing the version string might be your best bet:
you can use the «systeminfo» @ cmd.exe
I found a shorter way using ver as well:
Could be even shorter:
I found a shorter way using ver as well:
This will find XP, replace the string with your wanted versions
Type «ver» at a command prompt.
Next time around, since this isn’t really programming related but server or user related, you might try serverfault.com or superuser.com.
To find the windows version using WMIC you can use:
Maybe someone will need the following to determine the SKU (Win7). I’m using some of this script to pick the right OS and XML during sysprep. Hope it helps!
The internal command ver reports windows version number (which could have been learned by typing help at the command prompt).
There is a dynamic variable %CMDEXTVERSION% , but it hasn’t progressed in several releases so it’s only useful for delineating between Windows NT and Windows 2000 and newer. (Thanks @Joey, here.)
Here’s a batch to parse the output of ver for XP and newer, courtesy of Simon Sheppard:
And here’s my own fairly complete, largely academic, kick at the can which returns the parsed version number as environment variables:
How to get Windows version from command prompt or from PowerShell
But is there a way to get the exact version string using command line output similar to the one mentioned in the image?
The attached is the output of «winver» command from run. PS: I am looking for a batch or PowerShell command.
There are some alternates available to get the Windows version like this PowerShell command:
6 Answers 6
The following commands are is going to help you with that. If you need more information, just type in systeminfo:
The ver command shows something like this:
But in PowerShell (or Git Bash) you have to call it through the cmd command:
I found it somewhere, PowerShell:
To add to @Bonifacio ‘s answer:
Would be even better, because it returns only the ReleaseId value, which you could then pipe to a file. Especially useful if you have several hosts to deal with.
With system information you can only get the build with that value and go to Google to get the respective version.
However, one simple way is by searching the registry on the command line:
The reg query way suggested all output a little garbage.
Using a for loop with tokens will output clean information.
The tokens=3 refers to the third word from the original output.
You will need to double the % if running inside a bat file.
You can set the output as a variable by replacing echo %i with set build=%i
Also remember to escape ^ any special characters.
Lastly look at HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion for the string that has the required value. You may need to adjust the token count.
What version of Windows do I have?
As a Windows user, it’s important to know which operating system version you are using. You need this information when installing new programs and also for troubleshooting.
Microsoft provides details about the Windows version installed on your computer in several places in the operating system, e.g. in the Control Panel. There are three different ways of accessing the relevant system information. Let’s take a look at them now.
Checking your Windows version using a keyboard shortcut
The quickest way to find out your Windows version is using a keyboard shortcut. On newer systems, the steps are as follows:
- Simultaneously press the [Windows] key and the [Pause] key.
- A system information window will appear.
Under the heading “View basic information about your computer”, you will see the name of your operating system, e.g. Windows 10 Enterprise.
The window also contains an overview of the technical characteristics of your system, for example: processor architecture, installed memory (RAM) and system type (i.e. 32-bit or 64-bit). The next section shows the name of your computer and network domain settings. You can also see whether or not your Windows version is activated.
The system information window therefore contains all the information you need in order to install new programs.
However, it does not give you detailed information about your Windows version, such as the version number or the OS build number. You need this information if you want to check whether your operating system has all of the latest updates for example.
The [Windows] key + [Pause] key shortcut does not work on older Windows systems.
Detect Windows Server version 32/64-bit in CLI
What’s the best and quickest way to detect whether you’re running a 32 or 64-bit version of Windows Server from the command line?
(Cygwin is installed)
10 Answers 10
A slightly quicker way would be to check for the existence of the %ProgramFiles(x86)% directory. If it exists then you’re running 64-bit, if it doesn’t exist then you’re running 32-bit.
That will output 64-bit if the directory exists. That would fail, though, if it didn’t exist as a variable but it did exist as a directory (as %ProgramFiles(x86)%).
You can also use the find tool to have a more accurate way to determine bitness.
or using the systeminfo command previously
(included the /I to work across XP/2003/2008/etc)
This will return x86 on 32-bit systems and AMD64 (or IA64) on 64-bit systems.
It will list quite a bit, about 10 fields down there is one called System Type. This will tell you if it’s x86 or x64
This is locale dependent, and slow.
Notice, that it’s x86 in 32-bit cmd.exe .
Other way to check with a WMI query:
There are numerous ways to check the processor architecture under Windows:
The fastest, easiest, and most compatible way to check the processor architecture in at least Windows 2000 and up is to examine the PROCESSOR_ARCHITECTURE environment variable:
However, this can give different results, depending on the way in which the command-prompt is opened. To avoid getting “unexpected results” due to WoW64, you can read it directly from the registry (Microsoft made no less than two typos in the key):
reg query «HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment» /v PROCESSOR_ARCHITECTURE
Microsoft also suggests reading the hardware information store from the registry:
reg query «HKLM\Hardware\Description\System\CentralProcessor\0» /v Identifier
You can also check for the existence of the x86 version of the Program Files directory (or the environment variable that points to it) since it would only exist on a 64-bit system. Unlike the PROCESSOR_ARCHITECTURE variable, this is not dependant on the way that the command prompt is run since the directory exists (or not) regardless of how the prompt is opened:
::via env-var
if not defined ProgramFiles(x86) echo 32-bit
::via file-system
if not exist «%systemdrive%\Program Files (x86)» echo 32-bit
These methods can be combined in a single batch-file (e.g., cpuinfo.bat ) and provides a nice, lightning fast way to check the system from a standard Windows NT command-prompt without needing to resort to running other programs or frameworks.
This was tested on 32-bit and Intel 64-bit systems (please test on AMD64), giving correct results in