Windows 11 allows you to enable or disable SMB compression. Its most recent changes include the updated behavior of the SMB protocol compression feature. It allows you to reduce the size of the files transferred by the user, administrator, or applications over the network and thereby speed up the transfer of data. SMB compression has been used in the operating system before, but only files of a certain size were compressed.
When sending a file over the network, the algorithm compressed the first 524,288,000 bytes and then checked to see if 104,857,600 bytes were compressed within the 500MB range. If so, the compression continued, if not, the algorithm stopped working. Starting with Windows 11 22449, all files will be compressed with the SMB function enabled, without exception. To enable SMB compression in Windows 11 right now, you need to apply a registry tweak.
Enable SMB compression in Windows 11
- Open the registry editor. Press ⊞ Win + r and enter the
- Expand it to this branch:
- In the right column, create a new DWORD parameter. Name it
EnableCompressedTrafficand set its value to 1.
This tweak enables SMB compression with a decision algorithm, which means that the SMB component will always make a try for compression.
If you want all files to be compressed by default, you need to create two more values.
Always compress all files transferred over the network
- Open the Registry editor with the ⊞ Win + r
- Open the same key,
- Create or modify the
CompressibilitySamplingSizeDWORD parameter under the same registry key and set its value to
4294967295in decimal notation.
- Finally, create or change the
CompressibleThresholdDWORD value to 0.
Finally, it is easy to disable SMB Compression. Microsoft provides Registry values for that.
Disable SMB Compression
- Open the
- Open the following path
- Create here a new DWORD value
- Set its value data to 1.
This is how you disable SMB compression on Windows 11.
It is also worth noting that Microsoft allows disabling SMB compression with PowerShell. The command is
Set-SMbClientConfiguration -DisableCompression $true
Execute is from a PowerShell window running as Administrator.