Results.

SCEPTRA.TECH

VS Code Restricted Mode: Review an Unfamiliar Project Before You Trust It

VS Code Restricted Mode: Review an Unfamiliar Project Before You Trust It - original explanatory diagram

Downloading a useful-looking repository is not the same as approving everything it can run. Editor tasks, debugging configurations and extensions can execute code around the files you intended only to read. I would begin an unfamiliar project in VS Code's Restricted Mode, then decide whether it deserves more access.

What the trust decision controls

The official Workspace Trust documentation says Restricted Mode limits features that can cause automatic execution, including tasks, debugging, terminal behavior, workspace settings, extensions and AI agents. The current documentation also says trust is shared between the VS Code window and its Agents window.

This is a boundary for reviewing a project, not a malware verdict. VS Code warns that a malicious extension can ignore Restricted Mode. A trusted publisher name also does not substitute for understanding why an extension needs to run.

Review before enabling

  1. Check the repository's actual source and intended maintainer, not only the title in a download link.
  2. Read the project instructions without immediately running installation commands.
  3. Inspect the workspace's .vscode configuration, especially task definitions and paths to executables.
  4. Look at what setup scripts plan to install, fetch or change. If you cannot explain a command's effect, pause rather than treating it as required.
  5. Review the extensions requested for the project. Install only what the work needs from publishers you have checked.
  6. Trust the specific project folder only after the review supports doing so.

Do not trust a parent folder for convenience

VS Code lets you manage trusted workspaces from the Restricted Mode banner or the Workspaces: Manage Workspace Trust command. I would keep the scope narrow. Approving a broad downloads or projects directory can blur the difference between a project already reviewed and an unrelated one added later.

For example, a training folder might contain a known exercise alongside code received from an unknown forum account. They should not inherit the same decision merely because they sit beside each other on disk.

When a feature is disabled

A task or debug command asking for trust is not automatically broken. The restriction may be doing exactly what it is meant to do. Cancel the prompt if the code is still unfamiliar. Read the relevant task or configuration first and ask the maintainer for an explanation when necessary.

I would not disable Workspace Trust globally just to remove the banner. The useful end state is more specific: a reviewed project has the features it needs, while unfamiliar folders still open with restrictions. This article is based on the current VS Code documentation, not a security audit of any repository or a claim that Restricted Mode prevents every attack.

Sources and scope

Source-checked November 18, 2026. Original explanatory guide, not a hands-on test. Product behavior above is grounded in the official documentation linked below; workflow recommendations are editorial advice.

Comments