CMD Simulator
System Informationver

VER Command: Display Windows Version Number | Quick Reference Guide

Learn the VER command to instantly display Windows version numbers in CMD. Complete guide with examples, batch scripting tips, and version checking techniques.

Rojan Acharya··Updated Feb 13, 2026
Share

The VER command is a Windows Command Prompt utility that displays the operating system version number and build. Simply type VER to see your Windows version instantly—no parameters, no complexity. This lightweight command provides quick version verification for troubleshooting, compatibility checking, and batch script logic.

Whether you're a system administrator verifying OS versions across servers, a developer checking compatibility requirements, or an IT professional troubleshooting version-specific issues, VER delivers instant version information without the overhead of comprehensive system queries. Support technicians use VER as their first diagnostic step to confirm Windows version before applying fixes or installing software.

This comprehensive guide covers VER command syntax, practical examples for version checking and batch scripting, real-world use cases for IT professionals and developers, troubleshooting tips for version-related issues, and frequently asked questions. By the end, you'll efficiently verify Windows versions and incorporate version checks into your automation workflows.

What Is the VER Command?

The VER command is one of the simplest built-in Windows commands, available in all Windows versions from MS-DOS through Windows 11. It displays the Windows version number in a single line format, showing the major version, minor version, and build number. Unlike SYSTEMINFO which queries WMI and displays comprehensive system data, VER is instantaneous and requires no system services.

VER runs in Command Prompt (CMD), PowerShell, and batch files with identical behavior. The command accepts no parameters and always displays the same output format: "Microsoft Windows [Version X.X.XXXXX.XXXX]". It requires no special permissions and works in both standard and administrator command prompts. The output format has remained consistent across Windows versions, making it reliable for version detection in scripts.

Syntax

VER

Parameters

ParameterDescriptionRequired
(none)VER accepts no parametersN/A

Command Behavior

VER (No Parameters)

VER is executed without any parameters or switches. Simply type VER and press Enter to display the Windows version number. The command completes instantly (typically under 10 milliseconds) and always returns success (exit code 0), making it ideal for quick version checks and script validation.

The output format is consistent: "Microsoft Windows [Version X.X.XXXXX.XXXX]" where the version number indicates the Windows release. For example, Windows 10 shows version 10.0.XXXXX, Windows 11 shows 10.0.XXXXX (with build numbers 22000+), and Windows Server versions show their respective version numbers.

Understanding Version Numbers

Windows version numbers follow the format Major.Minor.Build.Revision. Major version 10.0 represents Windows 10, Windows 11, and Windows Server 2016/2019/2022 (all use major version 10). The build number distinguishes specific releases: Windows 10 builds range from 10240 to 19045, while Windows 11 starts at build 22000. Minor updates increment the revision number.

For example, "Microsoft Windows [Version 10.0.19045.3930]" indicates Windows 10, build 19045, revision 3930. This level of detail helps identify exact Windows versions for compatibility testing, patch verification, and troubleshooting version-specific issues.

Examples

Example 1: Display Windows Version

Scenario: You need to quickly check which Windows version is installed.

VER

Expected Output:

Microsoft Windows [Version 10.0.19045.3930]

Explanation: Displays the Windows version number instantly. This output indicates Windows 10, build 19045, revision 3930. Use this for quick version verification before installing software or applying patches.

Example 2: Check Version in Batch Script

Scenario: Your batch script needs to verify Windows version before executing version-specific commands.

@ECHO OFF
VER | FINDSTR /C:"10.0" >NUL
IF %ERRORLEVEL% EQU 0 (
    ECHO Windows 10 or 11 detected
) ELSE (
    ECHO Older Windows version detected
)

Expected Output:

Windows 10 or 11 detected

Explanation: Pipes VER output to FINDSTR to check for version 10.0 (Windows 10/11). The script branches based on version, enabling version-specific logic. Use this pattern for compatibility checks in deployment scripts.

Example 3: Save Version to File

Scenario: You need to log the Windows version for documentation or troubleshooting records.

VER > version.txt

Expected Output: Creates version.txt containing:

Microsoft Windows [Version 10.0.19045.3930]

Explanation: Redirects VER output to a text file for documentation. Useful for creating system logs, troubleshooting records, or compliance documentation that requires version verification.

Example 4: Compare Version Across Multiple Systems

Scenario: You need to verify Windows versions on multiple remote computers.

FOR /F %i IN (computers.txt) DO @ECHO %i: & @WMIC /NODE:%i OS GET Caption,Version

Expected Output:

SERVER01:
Caption                  Version
Microsoft Windows Server 2019  10.0.17763

SERVER02:
Caption                  Version
Microsoft Windows Server 2022  10.0.20348

Explanation: While VER doesn't support remote queries, this example uses WMIC to check versions on remote computers. For local version checks, VER is faster and simpler than WMIC.

Example 5: Extract Build Number Only

Scenario: You need just the build number for version comparison logic.

FOR /F "tokens=3" %%i IN ('VER') DO SET BUILD=%%i
ECHO %BUILD%

Expected Output:

[Version 10.0.19045.3930]

Explanation: Extracts the third token (version number) from VER output. For cleaner extraction, use additional parsing: FOR /F "tokens=3 delims=[]" %%i IN ('VER') DO SET BUILD=%%i to get just "10.0.19045.3930" without brackets.

Example 6: Version Check Before Software Installation

Scenario: Your installation script needs to verify minimum Windows version before proceeding.

@ECHO OFF
VER | FINDSTR /C:"10.0.19041" /C:"10.0.19042" /C:"10.0.19043" /C:"10.0.19044" /C:"10.0.19045" /C:"10.0.22000" >NUL
IF %ERRORLEVEL% EQU 0 (
    ECHO Compatible Windows version detected. Proceeding with installation...
    REM Installation commands here
) ELSE (
    ECHO ERROR: This software requires Windows 10 version 2004 or later, or Windows 11.
    EXIT /B 1
)

Expected Output:

Compatible Windows version detected. Proceeding with installation...

Explanation: Checks for specific Windows 10/11 builds before installation. This prevents installation failures on incompatible versions and provides clear error messages to users.

Example 7: Display Version with System Name

Scenario: You want to display both computer name and Windows version for documentation.

@ECHO OFF
ECHO Computer: %COMPUTERNAME%
VER

Expected Output:

Computer: DESKTOP-ABC123
Microsoft Windows [Version 10.0.19045.3930]

Explanation: Combines COMPUTERNAME environment variable with VER output for complete system identification. Useful in logs, reports, or troubleshooting documentation that needs both hostname and version.

Example 8: Version Check in PowerShell Script

Scenario: Your PowerShell script needs to verify Windows version using CMD's VER command.

$version = cmd /c ver
Write-Host "Detected: $version"

if ($version -match "10\.0\.2[2-9]") {
    Write-Host "Windows 11 detected"
} elseif ($version -match "10\.0") {
    Write-Host "Windows 10 detected"
}

Expected Output:

Detected: Microsoft Windows [Version 10.0.19045.3930]
Windows 10 detected

Explanation: Calls VER from PowerShell using cmd /c ver and parses output with regex. While PowerShell has native version checking ($PSVersionTable, [System.Environment]::OSVersion), VER provides consistent output format across all Windows versions.

Example 9: Create Version Report

Scenario: You need to generate a formatted version report for multiple systems.

@ECHO OFF
ECHO ========================================
ECHO Windows Version Report
ECHO ========================================
ECHO Computer Name: %COMPUTERNAME%
ECHO User: %USERNAME%
ECHO Date: %DATE% %TIME%
ECHO.
VER
ECHO ========================================

Expected Output:

========================================
Windows Version Report
========================================
Computer Name: DESKTOP-ABC123
User: JohnDoe
Date: 02/13/2026 14:30:25.45
Microsoft Windows [Version 10.0.19045.3930]
========================================

Explanation: Creates a formatted report combining system information with version data. Save to file with > report.txt for documentation or compliance records.

Example 10: Conditional Logic Based on Windows 11 Detection

Scenario: Your script needs different behavior for Windows 11 vs. Windows 10.

@ECHO OFF
VER | FINDSTR /C:"10.0.22000" /C:"10.0.22621" /C:"10.0.22631" >NUL
IF %ERRORLEVEL% EQU 0 (
    ECHO Windows 11 detected - using new UI commands
    REM Windows 11-specific commands
) ELSE (
    ECHO Windows 10 or earlier detected - using legacy commands
    REM Windows 10-specific commands
)

Expected Output:

Windows 10 or earlier detected - using legacy commands

Explanation: Distinguishes Windows 11 (build 22000+) from Windows 10 by checking build numbers. This enables version-specific features, UI adjustments, or API calls in your scripts.

Common Use Cases

1. Quick Version Verification for Troubleshooting

Support technicians use VER as their first diagnostic command to confirm Windows version before troubleshooting issues, ensuring they apply version-appropriate fixes and avoid incompatible solutions. This takes less than a second compared to navigating Settings or System Properties.

2. Batch Script Version Compatibility Checks

Developers use VER in batch scripts to verify minimum Windows version requirements before executing version-specific commands, preventing script failures and providing clear error messages when run on incompatible systems.

3. Software Installation Prerequisite Validation

Installation scripts use VER to check Windows version against software requirements, blocking installation on unsupported versions and displaying helpful error messages that guide users to upgrade their OS.

4. System Documentation and Inventory

IT administrators include VER output in system documentation, change logs, and configuration baselines to record exact Windows versions for compliance audits, disaster recovery planning, and configuration management.

5. Remote Support Session Verification

Remote support technicians ask users to run VER and read the output to quickly identify Windows version without navigating through multiple settings screens, especially useful when guiding non-technical users.

6. Automated Compliance Reporting

Compliance scripts use VER to verify systems run supported Windows versions, flagging end-of-life versions that require upgrades to maintain security compliance and vendor support eligibility.

7. Development Environment Validation

Developers use VER to verify their development environment matches target deployment environments, ensuring code and scripts work correctly on intended Windows versions before release.

8. Patch Management Verification

System administrators use VER before and after Windows updates to confirm version changes, verifying that feature updates and major upgrades completed successfully and systems run expected build numbers.

9. Scripted System Audits

Audit scripts use VER to collect Windows version data across enterprise systems, identifying version inconsistencies, unsupported versions, and systems requiring updates for standardization.

10. Training and Documentation

Technical trainers use VER to demonstrate version checking in command-line training sessions, teaching new IT staff how to quickly verify system versions without GUI navigation.

11. License Compliance Verification

License management scripts use VER to identify Windows editions and versions, ensuring license compliance and detecting unauthorized OS upgrades or downgrades.

12. Deployment Script Branching

Deployment automation uses VER to branch execution paths based on Windows version, deploying version-specific configurations, drivers, or applications appropriate for each OS version.

Tips and Best Practices

1. Use VER for Speed, SYSTEMINFO for Detail

VER executes in milliseconds while SYSTEMINFO takes several seconds. Use VER when you only need version numbers; use SYSTEMINFO when you need comprehensive system information including build details, service packs, and hotfixes.

2. Parse VER Output Carefully in Scripts

VER output format is consistent but includes brackets and spaces. Use FOR /F "tokens=3 delims=[]" to extract just the version number without brackets, making comparison logic cleaner and more reliable.

3. Remember Windows 11 Uses Version 10.0

Windows 11 reports version 10.0 (not 11.0) with build numbers 22000+. Check build numbers, not major version, to distinguish Windows 11 from Windows 10: builds 22000+ indicate Windows 11.

4. Combine VER with FINDSTR for Version Detection

Pipe VER to FINDSTR for version checking: VER | FINDSTR /C:"10.0.19041" checks for specific builds. Use multiple /C switches to check for multiple acceptable versions in a single command.

5. Use VER in Batch File Headers

Include VER output in batch file logs and headers to document which Windows version the script ran on, aiding troubleshooting when scripts behave differently across systems.

6. Don't Rely Solely on Major Version Numbers

Major version 10.0 covers Windows 10, Windows 11, and Windows Server 2016/2019/2022. Always check build numbers for accurate version identification, especially when version-specific features are required.

7. Test Scripts on Multiple Windows Versions

Use VER to verify your test environments match your target deployment versions. Test scripts on minimum supported version, maximum supported version, and current production version.

8. Document Version Requirements Clearly

When writing scripts that check versions with VER, document minimum required versions in comments and error messages, helping users understand why their version is incompatible.

9. Use PowerShell for Complex Version Logic

For complex version comparisons (greater than, less than, ranges), use PowerShell's [System.Environment]::OSVersion or Get-ComputerInfo which provide version objects with comparison operators.

10. Include VER in Error Reports

When scripts fail, include VER output in error logs and reports. This helps troubleshooters identify version-specific issues and provides context for bug reports.

11. Avoid Hardcoding Version Numbers

Instead of hardcoding version checks, use variables: SET MIN_BUILD=19041 then compare against VER output. This makes scripts easier to maintain when version requirements change.

12. Remember VER Shows Build, Not Edition

VER displays version numbers but not Windows edition (Home, Pro, Enterprise). Use WMIC OS GET Caption or SYSTEMINFO | FINDSTR /C:"OS Name" to identify editions when needed.

Troubleshooting Common Issues

Issue 1: VER Shows Unexpected Version Number

Problem: VER displays a version number that doesn't match what you see in Windows Settings.

Cause: Windows Settings may show marketing names ("Windows 10 version 22H2") while VER shows technical version numbers (10.0.19045). These represent the same version but in different formats.

Solution: Cross-reference VER output with Microsoft's Windows version history documentation to map build numbers to marketing names. For example, build 19045 is Windows 10 22H2, build 22621 is Windows 11 22H2.

Prevention: Understand that VER shows technical build numbers, not marketing version names. Keep a reference chart mapping build numbers to release names for your supported Windows versions.


Issue 2: Cannot Parse VER Output in Batch Script

Problem: Batch script fails to extract version number from VER output correctly.

Cause: VER output includes brackets, spaces, and multiple words, making simple token extraction unreliable. Default delimiters don't handle the format well.

Solution: Use proper FOR /F parsing: FOR /F "tokens=3 delims=[]" %%i IN ('VER') DO SET VERSION=%%i extracts just the version number. For build number only: FOR /F "tokens=2 delims=. " %%i IN ('VER ^| FINDSTR [0-9]') DO SET BUILD=%%i.

Prevention: Test version parsing logic on multiple Windows versions to ensure compatibility. Use robust parsing with explicit delimiters and token positions.


Issue 3: VER Output Differs Between CMD and PowerShell

Problem: VER output looks different when run in PowerShell vs. Command Prompt.

Cause: PowerShell may wrap or format VER output differently, especially when capturing to variables. The underlying version information is identical, but display formatting varies.

Solution: In PowerShell, use cmd /c ver to get consistent CMD-style output, or use PowerShell-native version checking: [System.Environment]::OSVersion.Version for version objects with direct property access.

Prevention: Use shell-appropriate version checking methods: VER in CMD/batch files, [System.Environment]::OSVersion in PowerShell scripts for consistent, predictable results.


Issue 4: Version Check Fails After Windows Update

Problem: Batch script version check stops working after Windows feature update.

Cause: Feature updates change build numbers, and scripts with hardcoded version checks fail when build numbers don't match expected values.

Solution: Update version check logic to include new build numbers, or use range checking instead of exact matches. For example, check if build >= 19041 instead of checking for exact build 19041.

Prevention: Design version checks with flexibility: use minimum version requirements rather than exact matches, and document version assumptions in script comments for easier maintenance.


Issue 5: Cannot Determine Windows 11 vs. Windows 10

Problem: VER shows version 10.0 for both Windows 10 and Windows 11, making them indistinguishable.

Cause: Microsoft kept major version 10.0 for Windows 11, differentiating only by build number. Windows 11 starts at build 22000, while Windows 10 ends at build 19045.

Solution: Check build numbers: VER | FINDSTR /C:"10.0.2[2-9]" detects Windows 11 (build 22000+). For precise detection: FOR /F "tokens=3 delims=. " %%i IN ('VER ^| FINDSTR [0-9]') DO IF %%i GEQ 22000 ECHO Windows 11.

Prevention: Always check build numbers, not just major version, when distinguishing Windows 10 from Windows 11. Document build number thresholds in your scripts.


Issue 6: VER Output Doesn't Show Detailed Update Information

Problem: VER shows build number but not specific update version (like 22H2, 21H2).

Cause: VER only displays technical version numbers, not marketing names or update versions. It shows build numbers which must be manually mapped to update versions.

Solution: Use SYSTEMINFO | FINDSTR /C:"OS Name" /C:"OS Version" for more detailed version information, or reference Microsoft's build number documentation to map VER output to update versions.

Prevention: Maintain a reference document mapping build numbers to update versions for your supported Windows releases. Use SYSTEMINFO when you need detailed version information beyond basic build numbers.

Frequently Asked Questions

What is the difference between VER and SYSTEMINFO?

VER displays only the Windows version number in a single line and executes instantly, while SYSTEMINFO shows comprehensive system information including OS details, hardware specs, memory, network adapters, and hotfixes, taking several seconds to complete. Use VER for quick version checks; use SYSTEMINFO for detailed system information.

Can VER check version on remote computers?

No, VER only displays version information for the local computer and doesn't support remote queries. For remote version checking, use WMIC /NODE:computername OS GET Caption,Version or PowerShell's Invoke-Command -ComputerName server -ScriptBlock {[System.Environment]::OSVersion}.

How do I determine if a system is Windows 10 or Windows 11 using VER?

Check the build number: Windows 11 uses build 22000 and higher, while Windows 10 uses builds up to 19045. Use VER | FINDSTR /C:"10.0.2[2-9]" to detect Windows 11, or parse the build number and check if it's >= 22000.

Why does Windows 11 show version 10.0 instead of 11.0?

Microsoft chose to keep the major version number at 10.0 for Windows 11 to maintain application compatibility. Many applications check major version numbers, and changing to 11.0 would break compatibility checks. Build numbers (22000+) distinguish Windows 11 from Windows 10.

Can I use VER to check Windows edition (Home, Pro, Enterprise)?

No, VER only shows version numbers, not Windows editions. Use WMIC OS GET Caption or SYSTEMINFO | FINDSTR /C:"OS Name" to see the full OS name including edition (e.g., "Microsoft Windows 10 Pro").

How do I extract just the build number from VER output?

Use FOR /F parsing: FOR /F "tokens=3 delims=[]" %%i IN ('VER') DO SET VERSION=%%i extracts the version string. For just the build number: FOR /F "tokens=3 delims=. " %%i IN ('VER ^| FINDSTR [0-9]') DO SET BUILD=%%i extracts the third segment (build number).

Does VER work in PowerShell?

Yes, VER works in PowerShell but returns output as a string. For PowerShell scripts, use native version checking: $PSVersionTable.PSVersion for PowerShell version or [System.Environment]::OSVersion.Version for Windows version with direct property access.

Can I use VER to check if Windows is activated?

No, VER only shows version numbers, not activation status. Use slmgr /xpr or slmgr /dli to check Windows activation status. For detailed licensing information, use WMIC PATH SoftwareLicensingProduct WHERE "PartialProductKey <> null" GET Name,LicenseStatus.

Why does VER show different numbers than winver?

VER shows the technical version number (e.g., 10.0.19045.3930) while winver (Windows Version dialog) shows marketing names (e.g., "Windows 10 Version 22H2"). They represent the same version in different formats—VER for technical use, winver for user-friendly display.

How often do Windows build numbers change?

Build numbers change with each Windows update: major feature updates change the third segment (e.g., 19041 to 19042), while cumulative updates change the fourth segment (revision number). Monthly quality updates typically increment the revision number.

Can I use VER to detect Windows Server versions?

Yes, VER works on Windows Server and displays version numbers like 10.0.17763 (Server 2019) or 10.0.20348 (Server 2022). However, use SYSTEMINFO | FINDSTR /C:"OS Name" to distinguish between server editions (Standard, Datacenter) and desktop Windows.

Is there a way to make VER output more detailed?

No, VER has no parameters and always shows the same single-line output. For more detailed version information, use SYSTEMINFO, WMIC OS GET Caption,Version,BuildNumber, or PowerShell's Get-ComputerInfo cmdlet.

Related Commands

SYSTEMINFO

Comprehensive system information command that displays detailed OS version, hardware specs, memory, network adapters, hotfixes, and configuration. Much more detailed than VER but slower to execute.

When to use: Use SYSTEMINFO when you need detailed system information beyond just version numbers. Use VER for quick version checks in scripts where speed matters.

HOSTNAME

Displays the computer's hostname. Often used alongside VER to identify both system name and version for documentation and troubleshooting.

When to use: Use HOSTNAME with VER to create complete system identification: HOSTNAME & VER shows both computer name and Windows version in two lines.

WMIC OS GET

WMI command-line tool that queries OS information including version, build number, edition, and architecture. More flexible than VER for detailed version queries.

When to use: Use WMIC OS GET Caption,Version,BuildNumber,OSArchitecture when you need structured version data with edition and architecture information.

winver (GUI)

Graphical "About Windows" dialog that displays Windows version with marketing names (e.g., "Version 22H2") and build numbers in a user-friendly format.

When to use: Use winver for interactive version checking with user-friendly display. Use VER in scripts and command-line workflows.

Get-ComputerInfo (PowerShell)

PowerShell cmdlet that retrieves comprehensive computer information including detailed OS version, edition, build, and architecture as PowerShell objects.

When to use: Use Get-ComputerInfo in PowerShell scripts for object-based version information with direct property access. Use VER in CMD/batch scripts.

[System.Environment]::OSVersion (PowerShell)

PowerShell .NET method that returns OS version as an object with Major, Minor, Build, and Revision properties for easy comparison and logic.

When to use: Use in PowerShell scripts when you need version comparison logic (greater than, less than, ranges) which is easier with version objects than string parsing.

Quick Reference Card

CommandPurposeExample Use Case
VERDisplay Windows versionQuick version check
VER > version.txtSave version to fileDocumentation and logs
VER | FINDSTR "10.0"Check for Windows 10/11Version validation in scripts
HOSTNAME & VERShow name and versionSystem identification
FOR /F "tokens=3" %%i IN ('VER')Extract version numberParse version in batch script
VER | FINDSTR "10.0.2[2-9]"Detect Windows 11Windows 11 detection logic
cmd /c ver (PowerShell)Get version in PowerShellCross-shell version check
VER | FINDSTR "10.0.19041"Check specific buildCompatibility verification
@ECHO %COMPUTERNAME% & VERSystem report headerLog file identification
VER && ECHO CompatibleVersion check with actionConditional script execution

Try It Yourself

Ready to master Windows version checking? Practice using the VER command in our interactive Windows Command Simulator. Experiment with version detection, batch script logic, and build your command-line expertise in a safe, risk-free environment.

Launch the Windows Command Simulator to start practicing VER commands now.

Want to explore more Windows commands? Check out our Complete Windows Commands Reference for detailed guides on over 200 CMD commands, including system information, file management, networking, and process control tools.

Related Guides:

Summary

The VER command is the fastest, simplest way to check Windows version numbers from the command line, displaying version and build information in a single line with instant execution. Whether you're running VER interactively for quick version verification or incorporating it into batch scripts for version compatibility checks, this lightweight command provides essential version information without the overhead of comprehensive system queries.

We covered VER command syntax (which accepts no parameters), understanding version number formats (major.minor.build.revision), and ten practical examples demonstrating version checking, batch script integration, version parsing, and conditional logic based on Windows versions. The command works identically across all Windows versions and requires no special permissions or system services.

Key use cases include quick version verification for troubleshooting, batch script compatibility checks, software installation prerequisite validation, system documentation, remote support session verification, and automated compliance reporting. IT professionals rely on VER for its speed and simplicity when version numbers are all they need.

Remember that Windows 11 reports version 10.0 (not 11.0) with build numbers 22000 and higher, so always check build numbers to distinguish Windows 11 from Windows 10. Use VER for speed when you only need version numbers, and use SYSTEMINFO when you need comprehensive system information. Parse VER output carefully in scripts using proper FOR /F token extraction with explicit delimiters.

Practice using VER regularly to build familiarity with Windows version numbers and their relationship to feature updates and releases. The more you integrate VER into your diagnostic and scripting workflows, the faster you'll verify compatibility, troubleshoot version-specific issues, and automate version-dependent logic. Start with simple version checks, then expand to batch script integration and automated version validation as your confidence grows.