Open in the explorer

Markdown preview: Show images from local and network sources

Type
Computer and user
GPO path
Computer Configuration › Policies › Administrative Templates › Microsoft PowerToys › File Explorer Preview User Configuration › Policies › Administrative Templates › Microsoft PowerToys › File Explorer Preview
Supported on
PowerToys version 0.101.0 or later
ADMX file
PowerToys.admx
Internal name
PowerToys/MarkdownAllowLocalImages

Explanation

This policy configures whether images from local and network (UNC) sources should be displayed in Markdown file previews.

If you enable this setting, images from the document's folder and network shares will always be shown and the user won't be able to disable it.

If you disable this setting, all images will be blocked and the user won't be able to enable local image rendering.

If you don't configure this setting, users are able to enable or disable showing local images.

Note: Online/remote images (http/https URLs) are always blocked regardless of this setting. Images are rendered inside a sandboxed WebView2 control with scripts disabled. The Mark-of-the-Web (Zone Identifier) is not checked; access is controlled by path validation against the document's directory (local) or share root (UNC).

Registry

HKEY_LOCAL_MACHINE\Software\Policies\PowerToys
HKEY_CURRENT_USER\Software\Policies\PowerToys
Value name
MarkdownAllowLocalImages
StateValue written
EnabledREG_DWORD = 1
DisabledREG_DWORD = 0

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.

Computer (HKLM)

Enable

# Enable: PowerToys/MarkdownAllowLocalImages
$k = 'HKLM:\Software\Policies\PowerToys'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'MarkdownAllowLocalImages' -Value 1 -Type DWord

Disable

# Disable: PowerToys/MarkdownAllowLocalImages
$k = 'HKLM:\Software\Policies\PowerToys'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'MarkdownAllowLocalImages' -Value 0 -Type DWord

Revert to "Not configured"

# Revert to "Not configured": PowerToys/MarkdownAllowLocalImages
$k = 'HKLM:\Software\Policies\PowerToys'
Remove-ItemProperty -Path $k -Name 'MarkdownAllowLocalImages' -ErrorAction SilentlyContinue

User (HKCU)

Enable

Disable

Revert to "Not configured"

Application

Microsoft PowerToys (Microsoft) — November 2026 templates

Official templates downloaded on November 12, 2026.