Skip to content
Office Deployment Tool

Office Deployment Tool

Office Deployment Tool

For installing Microsoft office in an enterprise environment it may be more suitable to use the office deployment tool rather than the standard installer downloaded from the office website.

The Office deployment tool allows for an automated installation with options.

See documentation here: https://docs.microsoft.com/en-gb/deployoffice/overview-office-deployment-tool

Download here: https://www.microsoft.com/en-us/download/details.aspx?id=49117

Configuration and Use

The ODT requires the configuration of an xml file to run.

The tool itself is run from the command line with the following command - run in the same directory as teh setup.exe and configuration xml file (run as admin): First download the required packages:

  • .\setup.exe /download .\configXmlFile.xml

Then Install:

  • .\setup.exe /configure .\configXmlFile.xml

The tool can also be used to download the install package using the /download switch and an xml file.

You can get a file generated with this tool if you do not want to create it yourself:

https://config.office.com/deploymentsettings

Example xml file


This will configure the install to use the en-gb language with some of the apps excluded from install with the shared licences active.

The shared licences is useful for any servers that have multiple users and are compatible with the O365 enterprise licences (E3 + E5 etc)

The display level sets if the user of the computer will see the installer and if they are required to accept the EULA

To install from a network or local location you will need to run the /download command first specifying the location/path in the “Add” section:


The sourcepath will then need to be specified in the xml file used when installing using the /configure switch.

After Installation configuration

After installing you can update the Office behavior - use the following commands to update/change:

rem Mount the default user registry hive reg load HKU\TempDefault C:\Users\Default\NTUSER.DAT rem Must be executed with default registry hive mounted. reg add HKU\TempDefault\SOFTWARE\Policies\Microsoft\office\16.0\common /v InsiderSlabBehavior /t REG_DWORD /d 2 /f rem Set Outlook’s Cached Exchange Mode behavior rem Must be executed with default registry hive mounted. reg add “HKU\TempDefault\software\policies\microsoft\office\16.0\outlook\cached mode” /v enable /t REG_DWORD /d 1 /f reg add “HKU\TempDefault\software\policies\microsoft\office\16.0\outlook\cached mode” /v syncwindowsetting /t REG_DWORD /d 1 /f reg add “HKU\TempDefault\software\policies\microsoft\office\16.0\outlook\cached mode” /v CalendarSyncWindowSetting /t REG_DWORD /d 1 /f reg add “HKU\TempDefault\software\policies\microsoft\office\16.0\outlook\cached mode” /v CalendarSyncWindowSettingMonths /t REG_DWORD /d 1 /f rem Unmount the default user registry hive reg unload HKU\TempDefault

rem Set the Office Update UI behavior. reg add HKLM\SOFTWARE\Policies\Microsoft\office\16.0\common\officeupdate /v hideupdatenotifications /t REG_DWORD /d 1 /f reg add HKLM\SOFTWARE\Policies\Microsoft\office\16.0\common\officeupdate /v hideenabledisableupdates /t REG_DWORD /d 1 /f

==Office Updates== Manually check for and install office updates with the following command:

1
"C:\Program Files\Common Files\microsoft shared\ClickToRun\OfficeC2RClient.exe" /update user

Perform command hidden from users:

1
"C:\Program Files\Common Files\microsoft shared\ClickToRun\OfficeC2RClient.exe" /update user displaylevel=false forceappshutdown=false

==Office Activation Issues==

See the following guide for office activation reset:

https://learn.microsoft.com/en-us/office/troubleshoot/activation/reset-office-365-proplus-activation-state

Check office key being used with the tool:

1
2
3
4
5
cscript "C:\Program Files\Microsoft Office\Office16\OSPP.VBS" /dstatus #run the tool using full path
#go to the location of the office install to run the osp.vbs tool 
cscript .\ospp.vbs /dstatus 
#can also run to see all installed licenses 
cscript .\ospp.vbs /dstatusall

remove a license key from server:

1
cscript .\ospp.vbs /unpkey:

Add license to the server:

1
cscript .\ospp.vbs /inpkey:

Stop Office from trying to register device with AD

To stop the user being prompted with pop up message to prompt them to sign into the apps on the device, instead of having them select the “No, this app only” option you can add in a reg key and enable a group policy setting to prevent the device from being azure or hybrid joined:

1
2
3
4
5
6
7
#Reg key, add via Group policy with update option
HKLM\SOFTWARE\Policies\Microsoft\Windows\WorkplaceJoin
DWORD: BlockAADWorkplaceJoin
Value: 1

#Group policy setting:
Computer Configuration > Administrative Templates > Windows Components > Device Registration > Register domain joined computers as devices: Disabled