How to Use Proactive Remediations in Intune
Wouldn’t it be great to fix issues before users open a ticket?
That’s exactly what Proactive Remediations in Microsoft Intune allow you to do. Using detection and remediation scripts, you can automatically identify and resolve common problems silently, on a schedule, and at scale.
Here’s how it works, how to set it up, and examples you can use right away.
Proactive Remediations are part of the Intune Device Remediations feature, available to tenants with:
- Windows 10/11 Enterprise or Education
- Microsoft Intune Suite or E5 licenses
- Endpoint Analytics enabled
They consist of:
- A detection script: checks whether a problem exists
- A remediation script: runs only if detection reports a failure
Think of them as Intune’s way to enable self-healing endpoints.
Use Cases You Can Automate
- Restarting Windows Update service if stuck
- Re-enabling BitLocker if encryption is off
- Resetting a corrupted OneDrive sync folder
- Removing unwanted local admin accounts
- Reapplying registry-based settings (e.g. Teams optimization)
How to Set It Up (Updated Navigation)
Step 1: Go to the Intune Admin Center
Navigate to: Devices > Remediations
Step 2: Click + Create Package
Step 3:
- Give your script a name and description
- Upload a Detection Script (.ps1)
- Upload a Remediation Script (.ps1)
Step 4: Assign the package to the appropriate device group
Step 5: Choose the frequency (e.g., every 1 hour, 8 hours, daily)
Monitor status from the Deployment Status tab
Scripting Best Practices
- Detection scripts must return exit code 0 for compliant, 1 for non-compliant
- Remediation only runs if detection fails
- Always test scripts on pilot devices first
- Avoid forcing restarts or UI interaction
- Log outcomes to Event Viewer or a custom log file for auditing
Monitoring Remediation Results
Once deployed, go back to:
Devices > Remediations > [Your Script] > Device Status
There you’ll see:
- Detection passed/failed
- Remediation success/failure
- Timestamp of last run
Example Scripts
Example 1: Detection – BitLocker Not Enabled
$bitlocker = Get-BitLockerVolume -MountPoint "C:"
if ($bitlocker.ProtectionStatus -eq 1) {
exit 0 # BitLocker is enabled
} else {
exit 1 # BitLocker is not enabled
}Example 2: Remediation – Enable BitLocker (Silent)
Enable-BitLocker -MountPoint "C:" -EncryptionMethod XtsAes256 -UsedSpaceOnly -TpmProtectorExample 3: Detection – Windows Update Service Not Running
$service = Get-Service -Name wuauserv
if ($service.Status -eq 'Running') {
exit 0
} else {
exit 1
}Example 4: Remediation – Start Windows Update Service
Start-Service -Name wuauserv
Set-Service -Name wuauserv -StartupType AutomaticProactive Remediations are one of the most valuable tools in Intune for keeping devices healthy, especially in distributed environments.
They help you prevent tickets, reduce user frustration, and maintain compliance silently and automatically.
Start simple, test scripts in pilot groups, and build a library of reusable checks as your environment matures.
Comments
Post a Comment