Disattiva AutoPlay: valore del Registro di sistema NoDriveTypeAutoRunUtenteHKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer

ID criterio
Autorun
Ambito
Configurazione computer, Configurazione utente
Supportato in
Almeno Windows 2000
Origine
Administrative Templates (.admx) for Windows 11 2026 Update (26H2) (versione 1.0)
Categoria
Componenti di Windows › Criteri AutoPlay

Registro

NoDriveTypeAutoRun

REG_DWORDUtenteComputer
Valore abilitato
Dipende dal valore dell'opzione
Elemento
Disattiva AutoPlay per:
Opzioni
VoceValore memorizzato
CD-ROM e unità rimovibili181
Tutte le unità255
Applica con .reg · CMD · PowerShell
UtenteImpostazione per account
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer]

; Opzioni (usarne solo una)
; CD-ROM e unità rimovibili
"NoDriveTypeAutoRun"=dword:000000b5
; Tutte le unità
"NoDriveTypeAutoRun"=dword:000000ff
CMD
:: Opzioni (usarne solo una)

:: CD-ROM e unità rimovibili
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 181 /f
:: Tutte le unità
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
PowerShell
# Comune: crea la chiave
New-Item -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer' -Force | Out-Null

# Opzioni (usarne solo una)
# CD-ROM e unità rimovibili
New-ItemProperty -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer' -Name 'NoDriveTypeAutoRun' -PropertyType DWord -Value 181 -Force | Out-Null
# Tutte le unità
New-ItemProperty -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer' -Name 'NoDriveTypeAutoRun' -PropertyType DWord -Value 255 -Force | Out-Null
ComputerImpostazione globale del computer
.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer]

; Opzioni (usarne solo una)
; CD-ROM e unità rimovibili
"NoDriveTypeAutoRun"=dword:000000b5
; Tutte le unità
"NoDriveTypeAutoRun"=dword:000000ff
CMD
:: Opzioni (usarne solo una)

:: CD-ROM e unità rimovibili
reg add "HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 181 /f
:: Tutte le unità
reg add "HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoDriveTypeAutoRun" /t REG_DWORD /d 255 /f
PowerShell
# Comune: crea la chiave
New-Item -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer' -Force | Out-Null

# Opzioni (usarne solo una)
# CD-ROM e unità rimovibili
New-ItemProperty -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer' -Name 'NoDriveTypeAutoRun' -PropertyType DWord -Value 181 -Force | Out-Null
# Tutte le unità
New-ItemProperty -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer' -Name 'NoDriveTypeAutoRun' -PropertyType DWord -Value 255 -Force | Out-Null