Battery report of Windows computer using Powershell

Comprehensive details of the battery of your notebook computer can be generated through a single command in Powershell. The simplest approach to finding the battery report is available for Windows computers. I have tested it on Windows 10 and Windows 11 without any issues.

Before looking at the Powershell command that can generate a battery report on Windows 11 computer, it may be pertinent to mention that the said battery report contains the following details of your laptop or notebook battery:

  • System details including the BIOS version
  • The capacity of the laptop battery
  • Battery usage over the past week or 7 days duration of time

To write the PowerShell command, you will need to initiate a Powershell session on your Windows 11 computer. You can do so by typing pwsh in the search box on Windows 11 toolbar. You need to run pwsh as administrator on the local computer. The screenshot below shows how you can launch Powershell on a Windows 11 computer:

pwsh command

Battery report using Powershell on Windows 11 and Windows 10

Battery report on a local computer can be generated using the powercfg command in the Powershell session. The exact command is shared below:

powercfg /batteryreport

This command, without any additional parameter, generates a detailed battery report for the notebook or laptop computer and saves it as an html file in the default location. The default location for the file is under the system root in which Windows is installed. The battery report is saved as a battery-report.html file. Obviously, you can change the location and name of the file in the command itself.

The command output of this battery report Powershell cmdlet is displayed below in the screenshot. The screenshot does not include the full HTML file because of obvious reasons. But, you can have a look at how the battery report for a Windows computer is laid out on the screen. The information about the battery is organized in multiple sections.

The command output on the screen is brief. However, the battery-report.html file is filled with comprehensive system and battery details. A screen grab of the first half of the file looks like the display showed below:

Battery report using Powershell on Windows 10 and Windows 11.

Apart from using the powercfg command in the Powershell session, we can also use one of the existing classes to generate details of the battery on the notebook computer. Win32_battery is the class that can be queried upon in Powershell for seeking battery details of a laptop computer.

Battery details of the laptop using WMIObject in Powershell

WMI Object can be used to fetch battery details of a laptop computer that runs Windows 10 or Windows 11 computer. WMI Object will use the underlying Win32_battery class to find these details.

The exact command that can be used to display the battery information of a Windows 11 laptop is shared below:

Get-WMIObject Win32_battery

The command output for this shares all the details of the available battery slots, the battery being used, and the capacity of the battery. In our experience, it is better to qualify this command and seek the more essential details as displayed in the command below:

At any point, you may be interested in fetching the details of the battery and the capacity of charge remaining in percentage terms.

Get-WMIObject Win32_battery | Select DeviceID, EstimatedChargeRemaining

The command output of this Powershell directive will show the name of the battery and the available battery charge in terms of percentage values.

Battery details in Poweshell for a Windows 10 and Windows 11 computer

Battery details of Windows 11 laptop using CIM Instance in Powershell

We can also use CIM Instance to query the Win32_battery class and find the details of battery on a Windows 10 or Windows 11 computer. The command output of the CIM Instance command directive is similar to what we get with the WMI Object directive. The exact command to retrieve battery details for a Windows 11 notebook computer is given below:

Get-CIMInstance Win32_battery | Select DeviceID, EstimatedChargeRemaining

The output from this command is displayed below for your ready reference:

Battery report in Powershell using Ciminstance on Windows 11 and Windows 10


We have seen that the details of notebook batteries can be found using any one of the three methods shared in this tutorial. Personally speaking, powercfg command provides much more relevant details about the battery, including the charge percentage available on the computer. So, if possible, use the powercfg command for getting a detailed battery report in an HTML file format.

You can use these commands on a local computer. Or, you could connect to a remote computer using PSExec and run these commands on the remote computer for seeking the details of battery.

How useful was this post?

Click on a star to rate it!

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?

Rajesh Dhawan

Rajesh Dhawan is a technology professional who loves to blog about smart wearables, Cloud computing and Microsoft technologies. He loves to break complex problems into manageable chunks of meaningful information.