How to Fix Windows Script Host access is disabled on this machine

Are you receiving Windows Script Host error in Windows 10? Learn how to fix Windows Script Host access is disabled on this machine error in Windows 10 PC.

Windows Script Host access is disabled on this machine error is a very common error message which you must be familiar with if you use Windows as your primary operating system.

WSH or Windows Script Host (formerly known as Windows Scripting Host) is an automation tool or technology developed by Microsoft which has the ability to execute scripts in a variety of languages on your system such as batch files. These scripts can be run in either GUI mode (WScript.exe) or command line mode (CScript.exe).

Somewhen, you must have run a Windows file with the .bat extension which is a perfect example here to understand this automation technology.

windows script host access is disabled on this machine

Many malware like the HTML Malware also uses Windows Script Host to deploy their malicious code. And that’s why most of the system admins disable this feature.

But if the WSH is disabled, it will completely prevent users from running any scripts (VBScript, JScript scripts, and Windows Script Files) because these scripts depend on this automation technology and a few programs may also require this feature to be enabled in order to work properly.

So, if you have been getting popups that say “Windows Script Host access is disabled on this machine. Contact your administrator for details.” then today, we are going to help you in solving this issue and teach you how to fix Windows script host error.

Windows Script Host Access is Disabled on this Machine [Fix]

If the “Windows Script Host access is disabled on this machine” error message appears at startup or very frequently in regular intervals without you doing anything, then it’s quite possible that a malware script is trying to run in the background.

In such situations, your prime focus should be on finding and eliminating the malware from your system completely. So, first of all, run a malware scan on your system and remove every trace of malware completely from your Windows PC.

We’ve previously written plenty of virus and malware removal guides which you can use to remove malware from Windows 10 PC. You can check out our anti-malware software guide to find the best malware remover or use Malwarebytes to clean your system before you begin with the process.

You can also use Windows 10 Task Manager to find out which script is trying to run in the background that causing the error. To do so:

  • On the Task Manager, go to the Details tab and right-click on the column header and then click on the Select Columns.
  • Select the Command line checkbox and then click on the OK button.

Enabling the Command-line feature will display the complete path of the services running on your system. So from here, you can easily see the complete file path and name of the script file which is trying to run silently and causing this issue.

Another best way of finding out which script is trying to run that causing the error “Windows Script Host access is disabled on this machine” is to use Autoruns for Windows utility.

Autoruns (Autoruns.exe) is a software component of the Autostart Program Viewer that allows the user to see what programs, scripts, services, and processes are set to start automatically with the operating system.

How to Enable Windows Script Host Access in Windows 10

After identifying and removing malware completely, if you are quite certain that there is no malware trying to execute malicious batch files on your system now and you want to lift the Windows script host restriction then these are the two best ways to do so.

To enable Windows script host access, follow any of these methods according to your preferences and get rid of the Windows script host access is disabled on this machine error in Windows 10 PC:

Enable Windows Script Host Access using Registry Editor

If you know how to make changes to the registry keys and values then enabling Windows script host access using Registry Editor in Windows 10 is a quite easy task. Here’s how:

Step (1): At first, press the Windows + R keys together and then type regedit in the Run dialog box and then hit Enter key.

Step (2): Once the Registry Editor window is opened, navigate to the following key:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows Script Host\Settings

Step (3): Now in right-side pane, double-click on the Enabled entry and then set the Value Data 1 to enable Windows script host.

windows script host error

Step (4): And if there is no Enabled entry available in the right-side pane then you need to create it. Here’s how:

  • In right-side pane, right-click anywhere on the empty space and then select New > DWORD (32-bit) Value option.
  • Set the new value name as Enabled and then double click on it and change its Value data to 1.

Step (5): Finally, click on the OK button and then close the Registry Editor.

Similarly, navigate to the following key and set the Enabled entry’s Value Data as 1:

HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows Script Host\Settings

This is how you can easily enable Windows script host access in Windows 10 using the Registry Editor and get rid of the Windows script host access is disabled on this machine error message.

Enable Windows Script Host Access via Comand Prompt

If the above method seems complicated then an easier way to solve the Windows script host access is disabled on this machine error is to do it using the Command Prompt. Here’s how:

Step (1): At first, right-click on the Start button and then select Command Prompt (Admin) from the power user menu.

Step (2): Once the Command Prompt with administrator privileges is opened, execute these both commands one after the other:

REG DELETE “HKCU\SOFTWARE\Microsoft\Windows Script Host\Settings” /v Enabled /f

REG DELETE “HKLM\SOFTWARE\Microsoft\Windows Script Host\Settings” /v Enabled /f

That’s it! Once these commands are executed successfully, Windows script host access will be activated in Windows 10 and you won’t receive Windows 10 script host error pop-ups anymore.

Conclusion

If you have followed all these steps accurately then you will be able to successfully resolve the error message “Windows Script Host access is disabled on this machine. Contact your administrator for details.” on Windows 10 PC.

If you have any more questions for us regarding Windows script host access is disabled or just want us to help you navigate any more Windows Script Host error then do let us know in the comments below and we will certainly help you out.

You may also be interested in checking out:

Leave a Reply

Your email address will not be published. Required fields are marked *