允許診斷資料 的登錄值 AllowTelemetry使用者HKCU\Software\Policies\Microsoft\Windows\DataCollection

原則 ID
AllowTelemetry
適用範圍
電腦設定、使用者設定
支援的作業系統
至少需要 Windows Server 2016、Windows 10
來源
Administrative Templates (.admx) for Windows 11 2026 Update (26H2) (版本 1.0)
類別
Windows 元件 › 資料收集與預覽組建

登錄

AllowTelemetry

REG_DWORD使用者電腦
啟用時的值
取決於選項值
元素
-
選項
項目儲存的值
診斷資料關閉 (不建議)0
傳送必要的診斷資料1
傳送選擇性診斷資料3
以 .reg · CMD · PowerShell 套用
使用者各帳戶的設定
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\DataCollection]

; 選項 (只使用其中一個)
; 診斷資料關閉 (不建議)
"AllowTelemetry"=dword:00000000
; 傳送必要的診斷資料
"AllowTelemetry"=dword:00000001
; 傳送選擇性診斷資料
"AllowTelemetry"=dword:00000003
CMD
:: 選項 (只使用其中一個)

:: 診斷資料關閉 (不建議)
reg add "HKCU\Software\Policies\Microsoft\Windows\DataCollection" /v "AllowTelemetry" /t REG_DWORD /d 0 /f
:: 傳送必要的診斷資料
reg add "HKCU\Software\Policies\Microsoft\Windows\DataCollection" /v "AllowTelemetry" /t REG_DWORD /d 1 /f
:: 傳送選擇性診斷資料
reg add "HKCU\Software\Policies\Microsoft\Windows\DataCollection" /v "AllowTelemetry" /t REG_DWORD /d 3 /f
PowerShell
# 共通: 建立機碼
New-Item -Path 'HKCU:\Software\Policies\Microsoft\Windows\DataCollection' -Force | Out-Null

# 選項 (只使用其中一個)
# 診斷資料關閉 (不建議)
New-ItemProperty -Path 'HKCU:\Software\Policies\Microsoft\Windows\DataCollection' -Name 'AllowTelemetry' -PropertyType DWord -Value 0 -Force | Out-Null
# 傳送必要的診斷資料
New-ItemProperty -Path 'HKCU:\Software\Policies\Microsoft\Windows\DataCollection' -Name 'AllowTelemetry' -PropertyType DWord -Value 1 -Force | Out-Null
# 傳送選擇性診斷資料
New-ItemProperty -Path 'HKCU:\Software\Policies\Microsoft\Windows\DataCollection' -Name 'AllowTelemetry' -PropertyType DWord -Value 3 -Force | Out-Null
電腦整部電腦的設定
.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\DataCollection]

; 選項 (只使用其中一個)
; 診斷資料關閉 (不建議)
"AllowTelemetry"=dword:00000000
; 傳送必要的診斷資料
"AllowTelemetry"=dword:00000001
; 傳送選擇性診斷資料
"AllowTelemetry"=dword:00000003
CMD
:: 選項 (只使用其中一個)

:: 診斷資料關閉 (不建議)
reg add "HKLM\Software\Policies\Microsoft\Windows\DataCollection" /v "AllowTelemetry" /t REG_DWORD /d 0 /f
:: 傳送必要的診斷資料
reg add "HKLM\Software\Policies\Microsoft\Windows\DataCollection" /v "AllowTelemetry" /t REG_DWORD /d 1 /f
:: 傳送選擇性診斷資料
reg add "HKLM\Software\Policies\Microsoft\Windows\DataCollection" /v "AllowTelemetry" /t REG_DWORD /d 3 /f
PowerShell
# 共通: 建立機碼
New-Item -Path 'HKLM:\Software\Policies\Microsoft\Windows\DataCollection' -Force | Out-Null

# 選項 (只使用其中一個)
# 診斷資料關閉 (不建議)
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\DataCollection' -Name 'AllowTelemetry' -PropertyType DWord -Value 0 -Force | Out-Null
# 傳送必要的診斷資料
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\DataCollection' -Name 'AllowTelemetry' -PropertyType DWord -Value 1 -Force | Out-Null
# 傳送選擇性診斷資料
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\DataCollection' -Name 'AllowTelemetry' -PropertyType DWord -Value 3 -Force | Out-Null