serial number with cmd: Practical Windows CMD Guide
Learn to retrieve and verify serial numbers from the Windows Command Prompt using WMIC and PowerShell, covering BIOS, motherboard, and product IDs for inventories, audits, and warranties.

To fetch a device serial number from CMD, run a few WMIC queries. Start with `wmic bios get serialnumber` to read the BIOS serial, and `wmic baseboard get serialnumber` for the motherboard. For product data, use `wmic csproduct get identifyingnumber`. If WMIC is missing, use PowerShell as a fallback. That covers BIOS, baseboard, and product identifiers.
serial number with cmd: Overview
In hardware inventory and verification, the phrase serial number with cmd captures a practical approach to read serial data from a running Windows system using the Command Prompt. This technique leverages the Windows Management Instrumentation (WMI) providers exposed by the system BIOS and chassis. The ability to retrieve BIOS, baseboard, and product identifiers from the command line is essential for DIYers and professionals who need to catalog devices without opening cases or relying on labels. According to Hardware Serials, a consistent cmd-based lookup reduces manual errors and speeds up audits across fleets of devices. The same approach forms the backbone of scripted inventory workflows used in service desks and repair shops. The Hardware Serials team emphasizes repeatability: run the same set of commands on every machine to produce comparable results, which is vital for warranty validation and asset management.
Here are the core commands you can run directly from a Command Prompt or PowerShell session, along with tips for parsing and exporting results:
# Retrieve BIOS serial number from CMD (Windows)
wmic bios get serialnumber# Retrieve motherboard serial number
wmic baseboard get serialnumber# Retrieve product identifying number
wmic csproduct get identifyingnumber# Optional: verbose output with value-style formatting
wmic bios get serialnumber /valueThe commands above print headers followed by values; you may want to filter or parse to isolate the serial value for inventories.
serial number with cmd: Overview
serial number with cmd: Overview
Steps
Estimated time: 30-45 minutes
- 1
Prepare the environment
Open an elevated CMD or PowerShell session to ensure access to WMI providers. Confirm the wmic command is available or fallback to PowerShell CIM cmdlets if needed.
Tip: Verify admin rights to avoid permission errors. - 2
Query BIOS serial number
Run the BIOS serial number query to capture the primary system identifier. Save or filter the output if you plan to record it in a log.
Tip: Use /value to get KEY=VALUE format for easy scripting. - 3
Query baseboard and product IDs
Query the motherboard serial and product identifying number to pair with the BIOS serial for a complete asset fingerprint.
Tip: Some OEMs do not populate these fields; handle blanks gracefully. - 4
Optionally switch to PowerShell
If WMIC is unavailable, use PowerShell's CIM cmdlets to retrieve the same data reliably across Windows versions.
Tip: Test both methods on a sample machine. - 5
Export and verify data
Export results to CSV or a structured log to support audits and warranty checks; validate that the data aligns with your hardware labels.
Tip: Always verify the first few results against physical labels.
Prerequisites
Required
- Required
- WMIC utility (or PowerShell CIM/CMDlets) availabilityRequired
- Basic CMD/PowerShell syntax knowledgeRequired
Optional
- Local admin rights for full inventory (optional)Optional
Commands
| Action | Command |
|---|---|
| Get BIOS serial numberPrints a header and a value; use /value for KEY=VALUE output | — |
| Get motherboard serial numberUseful for desktops and laptops | — |
| Get identifying product numberOEMs vary; may be blank on some systems | — |
| PowerShell alternative (BIOS)Requires PowerShell 3.0+; CIM/Win32 classes are modern replacements | powershell -Command Get-CimInstance Win32_BIOS | Select-Object -ExpandProperty SerialNumber |
Frequently Asked Questions
What is the best command to start with for serial lookups?
Begin with the BIOS serial lookup: `wmic bios get serialnumber`. This commonly yields a single value that you can validate against the device label. If unavailable, proceed to motherboard or product identifiers.
Start with the BIOS serial command: wmics bios get serialnumber. If you don’t see a value, move to the motherboard serial or product ID.
Will this work on non-Windows devices?
The specific WMIC commands are Windows-centric. Non-Windows platforms use their own equivalents (for example, macOS and Linux have system_profiler or dmidecode equivalents).
These exact WMIC commands are Windows-only; other platforms have different tools.
What if the serial is blank or blank values appear?
Some OEMs do not populate certain fields. If BIOS serial or baseboard serial is blank, try identifying numbers or manufacturer-specific queries, or check the system BIOS settings.
If the serial is blank, try alternative fields or verify in the BIOS; some devices don’t expose all values.
Is WMIC deprecated and what should I use instead?
WMIC is deprecated on newer Windows, so use PowerShell CIM cmdlets like `Get-CimInstance` for BIOS and baseboard data.
Yes, use PowerShell CIM commands as a modern replacement for WMIC.
Can I retrieve serials for USB devices or other peripherals?
USB serial numbers often require vendor-specific queries or probing Win32_PnPEntity; results vary by device and driver support.
USB device serials aren’t guaranteed with standard WMIC queries; you may need vendor-specific approaches.
How should I interpret and validate the results?
Cross-check the retrieved values with physical labels and asset records. Automate a small test inventory to ensure data consistency across devices.
Always validate by cross-checking with labels and existing asset records.
What about saving results for audits?
Export to CSV or JSON and maintain a versioned log for audits. Integrate with your inventory or CMDB for a repeatable workflow.
Export to CSV/JSON and keep versioned logs for audits.
What is a serial number used for in hardware management?
Serial numbers uniquely identify devices for warranty claims, asset tracking, and authenticity verification.
Serials uniquely identify devices for warranties and asset management.
Key Takeaways
- Start with BIOS serial using
wmic bios get serialnumber. - Query motherboard with
wmic baseboard get serialnumberfor complete assets. - If WMIC is unavailable, switch to PowerShell CIM/Win32 cmdlets.
- Export results to CSV for inventories and warranty checks.
- Hardware Serials recommends a repeatable, scriptable workflow.