We can disable Windows automatic updates from command line using the below command. These examples are for Windows XP, Windows Server 2003 and Windows 7, not a guide for managing updates on Windows 11 & 10. Disabling updates prevents automatic installation of security fixes, so turn them back on after troubleshooting.
reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 1 /f
I tested this on Windows XP, Windows Server 2003 and Windows 7. After running the above command you may also see a balloon popping up near the system tray with the message “Your computer might be at risk… Automatic updates is turned off……“.
Note that this will not work if domain group policy is enforced and users are prohibited from changing the settings. In Windows 7, we can check the Windows Update window. Go to settings and see if the options are greyed out for ‘Important updates’. If so, the settings may be controlled by administrator/domain policy. In Windows XP, the same can be checked on the ‘Automatic updates’ tab in Computer properties (sysdm.cpl).
To enable automatic download and scheduled installation, set the registry value to 4. A value of 0 means automatic updates are not configured. Command is given below.
reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 4 /f
If you want to download updates but not install till the user acts on it then you can set the registry value to 3.
reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 3 /f
If you want to disable Automatic updates service then run the below command.
sc config wuauserv start= disabled
This changes the startup setting; it does not stop the service if it is already running.
If you want to stop Automatic updates service then run the below command.
net stop wuauserv
Command for starting automatic updates service (enable it first if it is disabled):
net start wuauserv
Command for setting the service to start automatically:
sc config wuauserv start= auto
Keep the space after start=. This sets the startup type but does not start the service immediately.
Errors
These commands require administrator rights. In Vista/Windows 7, run them from an elevated administrator command prompt. Otherwise you would get the following error.
c:>reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 1 /f ERROR: Access is denied.
I have recently encountered an error while upgrading a system to Win10. The automatic update process breaks my ethernet and wifi connection abilities. I’ve attempted to update and roll back the driver to no avail among other troubleshooting. End result, I rolled back to Win7 while looking for a fix. Do you know of a way to disable the automatic update process which runs on its own during an OS upgrade, or a workaround to prevent this?
Thank you in advance for your help.
I’m receiving ERROR: Invalid Syntax. Type “REG ADD /?” For usage
The service name is invalid when using command net stop wjajserv pls help
Command not working please help. Disabling it shows Sc is not an Internal and external command
Here is something better for people who might want to choose what they do before they do it.
https://pastebin.com/2qtqSDGG
this failed to work after i entered the respecive commands and restarted my computer, and then did it again. though i am running from an Elevated CMD, + i am an administrator.
what should i do?
sc config wuauserv start= disabled (with admin auth) not work in win 7 pro!
Dude, This Rocks in BLOCKING WINDOWS 10 Windows Update
This worked perfectly. Thank you.
Wondering if there is a way to have it NOT download and install IE 11. We have a client that runs software that is not compatible with that. They have close to 500 machines and for some reason their Corporate IT lets them slide on doing updates and rebooting. Ive got around 300 of those machines that need updates ran and this makes it much more time effective than calling each user and remoting into their machine.
I’m looking at Windows 7 and 10 and the value for automatic install of updates is 4, not zero. Zero is disabled. I’ve tested this myself by manually changing the setting and looking at the change in the registry.
I have tested this on Windows 10 Technical Preview and it can disable and stop the windows update service – will not issue
in this one the options are locked and the update have to be on all the time.
The last update keeps going to error: DPC Watchdog Violation and meant i had to keep rolling back my Laptop for it to work
Now i have no issue as the upated are fully disable and not running any more lol
If you use this on Windows 10 Tech Preview: Run CMD in Admin for it to work…
sounds like id-10-t error ….
Does nothing. According to the windows update page on control panel it says its still on auto update. And I can’t turn it off from there thats why I wanted a alternative like this.
I LOVE YOU.
Tested on Windows 8, works perfectly, went over a nasty virus that destroyed my admin access for many things such as Windows Update (can’t be eliminated without formatting the computer and I can’t afford to lose my programs).
Sweet. This worked perfectly and all on a remote machine in another country…. I just fell in love with psexec again…
It works very perfectly.
The Access Denied message comes if you don’t run command using Administrator privileges, the command works perfectly..you can as well use the GUI..it works perfectly
Run cmd as administrator
Thank you for pointing out the relevant registry keys and how to modify them, the information was most helpful.
How to check if windows automatic update is on?
Get the registry value using ‘reg query’ command. you can know the updates on/off status based on the registry value
Glad that the tip helped you..keep visiting the blog for many more tips..thank you..
Thank you so much!! Saved me from infinite looping on Vista Ultimate with automatic updates.
and 3 means Download udates but do not install
Thanks i tested that with Vista it worked for that too .
In my windows update page was having error i did nt have any way other than to disable or enable automatic updates through command prompt.
Best Regards
Kanwal
It can be used to enable also. The command would vary slightly.. just replace 1 with 0. Please see the command below after making this change..
reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 0 /f
thanks mate. one question, does this command only disable? or does it enable and disable?
I believe if you do “net start wuauserv”. The windows update will start to work
to disable you type in “net stop wuauserv” in the command promt.
Thanks for the tip.. I tried this on Windows 7 and it worked perfectly. Thanks again.