Open in the explorer

Custom markup warning

Type
User
GPO path
User Configuration › Policies › Administrative Templates › Microsoft Word 2016 › Word Options › Advanced
Supported on
At least Windows Server 2008 R2 or Windows 7
ADMX file
word16.admx
Internal name
word16/L_CustomMarkupWarning

Explanation

This policy setting specifies how Word behaves when opening a document that contains custom XML markup.

If you enable this policy setting, you can set the behavior to one of the following:

- 0: Do not prompt the user and silently remove the custom XML markup.

- 1: Prompt the user regarding the loss of custom XML markup. This is the default option.

- 2: Prompt the user regarding the loss of custom XML markup, and do not allow them to suppress this prompt.

- 3: Prompt the user regarding the loss of custom XML markup, and open the file read-only.

- 4: Prompt the user regarding the loss of custom XML markup, do not allow them to suppress this prompt, and open the file read-only.

- 5: Do not prompt the user and silently remove the custom XML markup, but open the file read-only.

Registry

HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\word\options
Value name
not defined in the ADMX

Enable / disable values: not defined in the ADMX (see the options below).

PowerShell

PowerShell commands that write to the registry what the policy would write. Values in angle brackets (<…>) must be replaced.

Writing directly to the registry bypasses Group Policy: if a GPO manages this value, it will be rewritten at the next gpupdate; otherwise the value stays in place (the "tattooing" effect). Prefer a GPO or, locally, LGPO.exe. Run PowerShell as administrator for HKLM. Some policies need a restart or gpupdate /force.

Enable

# Enable: word16/L_CustomMarkupWarning
$k = 'HKCU:\software\policies\microsoft\office\16.0\word\options'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
# Custom markup warning
# Possible options:
#   Do not prompt = 0
#   Prompt = 1
#   Always prompt = 2
#   Prompt and open the file read-only = 3
#   Always prompt and open the file read-only = 4
#   Do not prompt and open the file read-only = 5
Set-ItemProperty -Path $k -Name 'custommarkupwarning' -Value 1 -Type DWord

Disable

# Disable: word16/L_CustomMarkupWarning
# No value is written in the "Disabled" state (nothing defined in the ADMX)

Revert to "Not configured"

# Revert to "Not configured": word16/L_CustomMarkupWarning
$k = 'HKCU:\software\policies\microsoft\office\16.0\word\options'
Remove-ItemProperty -Path $k -Name 'custommarkupwarning' -ErrorAction SilentlyContinue

Options (1)

LabelControlRegistry valueREG typeConstraints / details
Custom markup warning:L_CustomMarkupWarningDropIDDrop-down listenumcustommarkupwarningREG_DWORD
Default choice (UI): #1
LabelValue
Do not promptREG_DWORD = 0
PromptREG_DWORD = 1
Always promptREG_DWORD = 2
Prompt and open the file read-onlyREG_DWORD = 3
Always prompt and open the file read-onlyREG_DWORD = 4
Do not prompt and open the file read-onlyREG_DWORD = 5

Application

Microsoft 365 Apps / Office (Microsoft) — November 2026 templates

Official templates downloaded on November 12, 2026.