# Script to Check Encryption Status of drives on Windows

Encryption is one of the fundamental ways of protecting the data stored on the devices. Most organizations prefer device encryption using BitLocker to prevent unauthorized access to corporate data on Windows devices. Yet, if you need to verify the encryption status of the devices, you can get it done with the help of terminal commands. The [Execute Custom Script](https://www.hexnode.com/mobile-device-management/help/executing-custom-scripts-for-windows/) action enables administrators to execute customized script commands directly from the Hexnode UEM console.

 Note: 
**Supported Versions**:

The scripts given below will be supported on the following versions:

- Windows 10 v1607+ (Pro, Enterprise, Education)
- Windows 11 (Pro, Enterprise, Education)

 

 Disclaimer:The sample scripts provided below are adapted from third-party open-source sites.

 

Batch Script 
-------------

`manage-bde` is a command-line tool that helps you to perform BitLocker operations from the Terminal. This command can also be used to retrieve the encryption status.

Script to check the encryption status

manage-bde -status C: |findstr /C:"Conversion Status"

   1

  manage-bde -status C: |findstr /C:"Conversion Status"

   

 

  

PowerShell Script 
------------------

You can obtain the encryption status of a volume encrypted with BitLocker Drive Encryption by using the following custom script.

Script to check the encryption status

Get-BitlockerVolume C: | Select -expand "VolumeStatus"

   1

  Get-BitlockerVolume C: | Select -expand "VolumeStatus"

   

 

  

 Notes:- It is recommended to manually validate the script execution on a system before executing the action in bulk.
- Hexnode will not be responsible for any damage/loss to the system on the behavior of the script.