Skip to content
Follow
Windows

How to Install VBScript in Windows 11

Richard
Written by
Richard
Updated 5 min read
How to Add Music Folders in Windows Media Player
How to Add Music Folders in Windows Media Player

VBScript is an older Microsoft scripting language. Many automation scripts and legacy business programs still depend on it, and Windows 11 can run them once it is installed. If a .vbs script fails to open with an error, VBScript is usually not installed on your PC, or the Windows Script Host tool it relies on is disabled.

Advertisement

Turning it back on takes a few minutes, either through Settings or from a command line. This guide covers both, plus uninstalling, deployment on managed networks and fixing install errors on 24H2. Installing VBScript needs an administrator account.

⚡ Quick Answer

Open Settings Apps Optional features, click View features, search for VBScript, check the box and click Install. Windows downloads and installs it from Windows Update ; your.vbs scripts run once complete, no restart needed.

Advertisement

Why use VBScript?

Microsoft is phasing out VBScript to improve system security. The language no longer gets improvements, and old scripting engines are a common route for malware. For that reason you should install it only if you really need it, typically for legacy software or old business scripts that cannot run any other way.

⚠️WarningIf you can, plan to move those scripts to PowerShell over time.

Microsoft has announced that VBScript will be removed from Windows in a future release, so a fix that works today may stop working later.

Security and Deprecation Roadmap

Microsoft has stopped updating VBScript. It gets no further improvements and carries a security risk, which is why Windows 11 treats it as an optional feature that you add yourself instead of something that is always there.

On recent builds, including 24H2, VBScript is a “feature on demand”. Windows downloads and installs it only when you ask for it. That is why you add it from Optional features, and why the install needs an internet connection in most cases.

Advertisement

Install or Uninstall via Settings

The easiest way to install VBScript on Windows 11 is through the Settings app. This works on Home, Pro and the other editions. You need to be signed in with an administrator account, or be ready to enter administrator credentials when Windows asks.

Use the numbered steps below. To remove the feature later, you follow the same path and choose Uninstall instead.

  1. Open the Windows Settings app by pressing Windows key + I. The Settings window opens with a list of categories on the left.
  2. Click on Apps on the left side. The Apps page opens on the right. On some 24H2 builds, Optional features sits under System instead of Apps. If you do not see it here, look under System.
windows 11 settings apps on menu
windows 11 settings apps on menu
  1. Select the Optional features tile. You should now see the list of features already installed on your PC, with an option to add new ones at the top.
windows 11 optional features tile
windows 11 optional features tile
  1. Click the View features button. A window opens with a search box and a list of features you can add.
windows 11 optional features view features button
windows 11 optional features view features button
  1. Search for VBScript, check the box, and click Next. If VBScript does not appear in the results, it may already be installed, or your PC may not be able to reach Windows Update. Check your internet connection and try again.
Windows install VBScript via the Settings app
Windows install VBScript via the Settings app
  1. Click Install to finish. Windows downloads and installs the feature, and the list shows its progress. Once it reports as installed, your .vbs scripts should be able to run. A restart is not normally needed, but if a script still fails, restart the PC and try again.
Windows install VBScript confirm install button
Windows install VBScript confirm install button
⚠️WarningTo uninstall later, return to the Optional features page, find VBScript in the list of installed features, expand it and select Uninstall.

Removing it again is a good idea once you no longer need the old scripts, since it reduces what an attacker could use on your PC.

Windows uninstall VBScript button
Windows uninstall VBScript button

Install or Uninstall via Command Line

If you prefer the command line, or Settings does not offer the feature, you can install VBScript from Windows Terminal. This also helps when you work over remote sessions or build scripts. The terminal has to run as an administrator, or the commands will fail with an access error.

Advertisement

To open it, right-click the Start button and choose Terminal (Admin). Click Yes when User Account Control asks for permission. The window title should show that it is running as Administrator.

Paste the command below to install the feature. Press Enter and wait for it to finish. It reports progress and a success message when the install is done.

💻Code
DISM /Online /Add-Capability /CapabilityName:VBSCRIPT~~~~

To remove it, run the command below from the same administrator terminal. If it says a restart is required, restart the PC to complete the removal.

💻Code
DISM /Online /Remove-Capability /CapabilityName:VBSCRIPT~~~~

Enterprise Management (GPO & Intune)

System administrators can deploy VBScript across many network computers at once using Group Policy (GPO) or Microsoft Intune. This keeps legacy applications working in a company setting while you stay in control of what gets installed.

Advertisement

Test the deployment on a small pilot group first. Make sure the target PCs can reach Windows Update or your internal update source, because the feature is downloaded when it is installed. Keep a list of the machines that need it, so you can remove it when the last legacy script is retired.

Troubleshooting 24H2 Errors

If the install fails on Windows 11 24H2, start by checking the feature status from PowerShell. Run the check command shown below. It tells you whether VBScript is present on the PC. If the feature is missing and the normal Settings route fails, use DISM (Deployment Image Servicing and Management, a tool for repairing Windows system files) to force the installation.

Run both tools from an administrator terminal. Also confirm that the PC has an internet connection, since the files come from Windows Update.

⬛PowerShell
Get-WindowsCapability -Online -Name VBSCRIPT~~~~

If the status shows 'NotPresent', use the DISM command mentioned earlier to install it. If errors persist, confirm that your user account has local administrator rights. A standard account cannot add or remove optional features.

Advertisement

If the install still fails after that, restart the PC, install any pending Windows updates and try again. Many feature-on-demand errors clear up once Windows Update is fully up to date.

Summary

VBScript is an older tool that Windows 11 does not include by default. You can add it manually through Optional features or the command line when old programs require it. Remove it again once you no longer need it.

Have a question about this guide?

Answered by AI from this guide. Good questions may be added to this page — please don't include personal details.

Tags: #Windows 11

Did this guide fix your problem?

Richard

About the Author

Richard

Tech Writer, IT Professional

Richard is a writer at Geek Rewind who turns complex IT tasks into clear, step-by-step guides. He draws on years of hands-on experience in system administration and enterprise IT operations, focusing on Windows, Linux and WordPress: the problems people actually run into, and the fixes that work. His server and WordPress guides come from systems he runs himself. Richard builds and maintains the platform behind Geek Rewind, from its Ubuntu servers and Nginx configuration to its custom WordPress plugins. Many new tutorials start with readers' questions, and he's always glad to answer them in the comments.

Advertisement

No comments yet — be the first to share your thoughts!

Leave a Comment

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