Configure compression for RemoteFX data: registry value MaxCompressionLevelComputerHKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services

Policy ID
TS_SERVER_COMPRESSOR
Scope
Computer Configuration
Supported on
At least Windows Vista with Service Pack 1
Source
Administrative Templates (.admx) for Windows 11 2026 Update (26H2) (version 1.0)
Category
Windows Components › Remote Desktop Services › Remote Desktop Session Host › Remote Session Environment

Registry

MaxCompressionLevel

REG_DWORDComputer
Enabled value
Depends on the option value
Element
RDP compression algorithm:
Options
ItemStored value
Optimized to use less memory1
Optimized to use less network bandwidth3
Balances memory and network bandwidth2
Do not use an RDP compression algorithm0
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services]

; Options (use only one)
; Optimized to use less memory
"MaxCompressionLevel"=dword:00000001
; Optimized to use less network bandwidth
"MaxCompressionLevel"=dword:00000003
; Balances memory and network bandwidth
"MaxCompressionLevel"=dword:00000002
; Do not use an RDP compression algorithm
"MaxCompressionLevel"=dword:00000000
CMD
:: Options (use only one)

:: Optimized to use less memory
reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "MaxCompressionLevel" /t REG_DWORD /d 1 /f
:: Optimized to use less network bandwidth
reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "MaxCompressionLevel" /t REG_DWORD /d 3 /f
:: Balances memory and network bandwidth
reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "MaxCompressionLevel" /t REG_DWORD /d 2 /f
:: Do not use an RDP compression algorithm
reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "MaxCompressionLevel" /t REG_DWORD /d 0 /f
PowerShell
# Common: create the key
New-Item -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Force | Out-Null

# Options (use only one)
# Optimized to use less memory
New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'MaxCompressionLevel' -PropertyType DWord -Value 1 -Force | Out-Null
# Optimized to use less network bandwidth
New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'MaxCompressionLevel' -PropertyType DWord -Value 3 -Force | Out-Null
# Balances memory and network bandwidth
New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'MaxCompressionLevel' -PropertyType DWord -Value 2 -Force | Out-Null
# Do not use an RDP compression algorithm
New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'MaxCompressionLevel' -PropertyType DWord -Value 0 -Force | Out-Null