Simple Method to Disable Office Online Repair with Intune PowerShell Script

In this blog post am going to cover how to Disable Office Online Repair with Intune PowerShell Script. Disabling Office Online Repair is essential for organizations that want to prevent users from modifying or reinstalling Microsoft Office without IT approval.

Online repair can reset Office settings and remove custom configurations, which may cause issues in managed environments. By disabling this feature, IT administrators can maintain control over Office deployments and ensure consistency across all devices.

This can be achieved by adding a Windows registry to disable the repair option. This prevents users from accessing the online repair option. Deploying this change via Microsoft Intune using a PowerShell script ensures that all managed devices receive the update without manual intervention.

Using Intune, administrators can automate deployment, enforce compliance, and monitor script execution across the organization. This approach simplifies IT management and reduces troubleshooting efforts caused by unauthorized Office repairs. If needed, IT teams can still perform repairs using alternative methods, ensuring that Office remains functional while maintaining control over its configuration.

Patch My PC
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 1
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 1

Reasons to Disable Office Online Repair

Here are the few main reasons why to disable Office Online Repair Option in production senarios. The below table shows more detaills.

ReasonsDescription
Prevents Unauthorized ChangesOnline repair resets Office settings, removing IT-enforced configurations and custom policies.
Maintains Configuration ConsistencyEnsures all managed devices follow the same Office settings and deployment standards.
Reduces Bandwidth ConsumptionOnline repair requires downloading large installation files, which can impact network performance.
Minimizes DowntimePrevents users from unintentionally reinstalling Office, avoiding unnecessary disruptions to their work.
Enhances IT ControlForces users to contact IT support for repairs, allowing administrators to apply controlled troubleshooting methods.
Prevents Loss of Add-ins & CustomizationsOnline repair can remove installed add-ins, requiring manual reinstallation by IT teams.
Improves Security & ComplianceEnsures that only authorized IT personnel can modify Office installations, maintaining security policies.
Supports Centralized ManagementAllows IT to manage Office repairs through Intune, SCCM, or other approved deployment tools.
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Table. 1

Create Disable Office Online Repair Using Intune PowerShell Script

Follow the below-mentioned steps to Disable Office Online Repair Using the Intune PowerShell Script. Here am using Platform script to configure the same. Log In to the Microsoft Intune Admin Center using your admin credentials.

Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 2
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 2

In the Basics details pane, we can give the PowerShell Script name “Disable Office Online Repair” If needed, provide a short script description here. I am giving it as “Adding Registry Key to Disable Office Online Repair Option” and click Next.

Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 3
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 3

Create a PowerShell Script to Disable Office Online Repair with Intune

Now, we can create a PowerShell Script to Disable Office Online Repair. It’s a registry key adding command via PowerShell. Note the commands below and save the script as Disable_OfficeOnlineRepair.ps1.

New-ItemProperty -Path “HKLM:\SOFTWARE\Policies\Microsoft\office\16.0\common\officeupdate” -Name “onlinerepair” -Value “0” -PropertyType DWord

In the Script settings pane, we can configure the settings according to our requirements. The first option is mandatory. We have to browse and select our saved PS Script here.

  • Script location – Browse and select the saved script Disable_OfficeOnlineRepair.ps1
  • Run this script using the logged on credentials – No
  • Enforce script signature check – No
  • Run script in 64 bit PowerShell Host – Yes
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 4
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 4

On the next page, leave the scope tags default; if any custom scope tag is available based on your requirement, you can also select it for this script deployment.

Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 5
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 5

Click on Next and assign the script to HTMD – Test Computers. You can click Add groups and select the required device group in the Included groups section.

Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 6
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 6

On the Review + Add pane, carefully review all the settings you’ve defined for the Disable Office Online Repair Using Intune PowerShell Script. Select Add to implement the changes once you’ve confirmed everything is correct.

Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 7
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 7

Monitor the Disable Office Online Repair PS Script Deployment

This Intune PowerShell Script has been deployed to the Microsoft Entra ID group (HTMD – Test Computers). The policy will take effect as soon as possible once the device is synced. To monitor the policy deployment status from the Intune Portal, follow the steps below.

  • Navigate to Devices > Windows > Scripts and remediations > Platform scripts

Search for the “Disable Office Online Repair” Script. The deployment status for this script can be seen under the Overview status. We can see that both the Device and User statuses have succeeded.

Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 8
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 8

End User Experience – Disable Office Online Repair Using Intune PowerShell Script

We have to check whether the Intune PowerShell Script has Disabled Office Online Repair or not. Log in to one of the policy-targeted devices. Open Registry Editor and follow the below registry path.

  • Open Run > Type Regedit > Navigate to Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\16.0\Common

As per your setting we can a new registry got created “onlinerepair” and the value is “0“. So, we can conclude that the Script deployment is working perfectly fine!

Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 9
Simple Method to Disable Office Online Repair with Intune PowerShell Script. Fig. 9

Need Further Assistance or Have Technical Questions?

Join the LinkedIn Page and Telegram group to get the latest step-by-step guides and news updates. Join our Meetup Page to participate in User group meetings. Also, Join the WhatsApp Community to get the latest news on Microsoft Technologies. We are there on Reddit as well.

Author

Vaishnav K has over 11 years of experience in SCCM, Device Management, and Automation Solutions. He writes and imparts knowledge about Microsoft Intune, Azure, PowerShell scripting, and automation. Check out his profile on LinkedIn.

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.