Key takeaways
- A VS Code extension is not sandboxed: its code runs in the extension host with the same rights as the editor and the user who started it.
- The Marketplace checks and the verified publisher badge do not review what the code does. Malicious versions of real extensions have reached users through automatic updates.
- Togoder Security reads every file in the VSIX: the extension's own code, its bundled dependencies, including minified bundles, and its helper scripts. Extension packs and extension dependencies are scanned too.
- Reports are public and shared. If someone scanned that version before, the result is free and needs no account.
- It covers the Visual Studio Marketplace (VS Code) and Open VSX (Cursor, VSCodium, Windsurf).
Are VS Code extensions safe?
Most are. The problem is that the editor gives you no way to see which ones are not. Three facts make an extension a good target for an attacker:
- No sandbox. An extension's entry point runs inside the editor's extension host with your user's full rights: files, network, child processes and the integrated terminal. It can read
~/.ssh,~/.npmrc, cloud credentials and the source code of every project you open. - It can run each time the editor starts. With
"activationEvents": ["*"]oronStartupFinished, the code runs without an action from you. - Updates are automatic. A sold or hijacked publisher account can push a malicious version to every user. The version you checked last month is not the version that runs today.
The editor's protections help, but they answer different questions:
| Protection | What it tells you | What it does not tell you |
|---|---|---|
| Verified publisher badge | The publisher proved that it controls a domain | What the code does |
| Marketplace malware checks | The package passed automatic checks when it was published | That nothing passed them; malicious extensions have |
| Workspace Trust | Code in a folder that you open is restricted | Anything about the extensions that you installed |
| Install count and reviews | The extension is popular | That today's version is the one those users reviewed |
Malicious extensions that reached users
- Nx Console (18 May 2026): version 18.95.0 of a widely used extension was malicious. It was published with a stolen contributor token and went out through automatic updates on the Visual Studio Marketplace and on Open VSX before it was removed. See our timeline.
- Checkmarx extensions on Open VSX (23 March 2026): compromised in the campaign that started with the Trivy attack. See the TeamPCP cascade.
- GlassWorm (October 2025): a worm that spread through Open VSX extensions and hid its payload in invisible Unicode characters.
In each case the extension was real or looked real, and the editor installed the malicious version by itself.
What the scan reads
- The extension's own code, starting with the activation entry point.
- Bundled dependencies: the
node_modulesfolder or the single minified bundle inside the VSIX, where a payload is easy to hide. - Helper scripts that the extension starts: shell, PowerShell, batch and Python.
- Everything that is installed with it: extension packs (
extensionPack) and extension dependencies (extensionDependencies).
The reviewer looks for credential and token theft, data sent to remote servers, downloaded and executed code, obfuscated loaders, backdoors and crypto-wallet theft. Each finding gives the file, the line and what the code does. How the review works is on the methodology page.
Check an extension now
- Find the extension's id. It is
publisher.name, for exampleesbenp.prettier-vscode, and it is in the address of its Marketplace page afteritemName=. - Open VS Code extension reports (or Open VSX reports for Cursor, VSCodium and Windsurf) and enter the id. If that version has a report, you see it immediately and it is free.
- If it has no report, start a scan with the ecosystem set to VS Code extension. You see the price first. Files that were reviewed before, also inside other extensions or npm packages, cost nothing.
Each report has a permanent address: https://security.togoder.click/vscode/publisher.name. Scripts can ask for the reports of many extensions in one free call:
curl -X POST https://security.togoder.click/api/extensions/check \
-H "Content-Type: application/json" \
-d '{"extensions": [{"id": "esbenp.prettier-vscode"}]}'
In the editor: scan, then install
The Togoder Security extension puts the same check inside VS Code:
- Scan, Then Install: right-click an extension in the Extensions view. After the scan, Install installs exactly the version that was scanned.
- Scan before an update: turn off automatic updates, and the Togoder Security view shows each installed extension, its scan status and newer releases. Scan Newest Release, Then Update does the two steps in the correct sequence.
- A status for each installed extension: no issues, a risk level, or not scanned. Flagged extensions are at the top. This lookup is free and needs no API key.
- Sign-in with an API key only. The editor never sees your GitHub or Google session. If you lose a machine, you revoke one key.
- No telemetry. The extension sends the ids and versions of extensions, not your code or file names. Its own code is one file that is not minified, with no dependencies.
Status: the editor extension is not in the Visual Studio Marketplace or Open VSX yet. Until it is, check an extension by its id on this site: the scan and the reports are the same.
What it costs
| Price | |
|---|---|
| Reports of versions that were scanned before | Free, no account |
| Price quote for a scan | Free |
| A scan in which every file was scanned before | Free, no account |
| Files that nobody scanned before | Paid from a prepaid balance (from $20) or a monthly plan (from $69) |
The price comes from the size of the new files. A small extension costs cents. A large extension with many bundled dependencies can cost some dollars, and you see the amount before you confirm. Details on the pricing page.
Limits
- A report without findings is not a guarantee. The model reads the code and does not run it. It lowers the risk, and it can miss things or flag code that is harmless.
- Native binaries are not reviewed, and files above the size limit are not reviewed. The report lists them.
- The editor has no hook before an install. An extension cannot stop the editor's own Install button or an automatic update. To scan first, use Scan, Then Install and turn off automatic updates.
- Extensions that are not in a gallery, for example a
.vsixfile from a website, cannot be scanned.
Extensions are one way into a developer machine. For the others, see npm supply chain attacks and scanning a lockfile in CI.
Frequently asked questions
Are VS Code extensions safe?
Most are, but an extension is not sandboxed: it runs with the full rights of the editor and can read your files, keys and tokens and use the network. Malicious extensions, and malicious updates of real extensions, have reached users through the Visual Studio Marketplace and Open VSX. Check the code of an extension before you install or update it.
Is Visual Studio Code safe?
The editor itself is made by Microsoft and its source code is public. The risk is in third-party extensions, which run with the same rights as the editor, and in the folders you open. Install few extensions, check them, and turn off automatic updates for extensions that you have not reviewed.
How do I check if a VS Code extension is safe?
Check the publisher, the repository link and the install count, then look at the code. Togoder Security does the last step: enter the extension's id (publisher.name) at https://security.togoder.click/vscode and an AI model reads every file in the VSIX, bundled dependencies included. Reports of versions that were scanned before are free.
Does the verified publisher badge mean an extension is safe?
No. The badge means that the publisher proved control of a domain. It is not a review of the code, and a verified publisher's account can be hijacked.
Does this work for Cursor, VSCodium and Windsurf?
Yes. Those editors install extensions from Open VSX. Togoder Security scans Open VSX extensions the same way, with reports at https://security.togoder.click/openvsx.
What is a VSIX file?
A VSIX file is the package format of a VS Code extension: a ZIP archive with the extension's manifest (package.json), its code and its bundled dependencies. The scan downloads the VSIX from the gallery and reads the files in it without running them.