How to Install VsCode Extension from your custom or local repo
Install VS Code or Cursor extensions from local or remote repositories without the marketplace.
There are several ways to install a Visual Studio Code (VS Code) extension without using the official marketplace—useful when working on custom, private, or modified extensions. Below are practical, up-to-date methods for installing extensions from both local and remote repositories, compatible with VS Code and Cursor.
Installing from a Local Repository
Method 1: Using vsce to package and install
Install the VS Code Extension Manager globally:
1
npm install -g @vscode/vsce
Navigate to your extension’s root directory:
1 2
npm install # install dependencies vsce package # package the extension as .vsix
Install the
.vsixfile:In VS Code:
- Open Extensions view (
Ctrl+Shift+XorCmd+Shift+X) - Click the
⋯(three dots) menu at the top - Select Install from VSIX…
- Choose your
.vsixfile
- Open Extensions view (
In Cursor:
Cursor does not always display the
⋯menu. Instead:- Use the Command Palette (
Cmd+Shift+P) and runExtensions: Install from VSIX - Or open the terminal and run:
1
cursor --install-extension path/to/your-extension.vsix- Use the Command Palette (
Method 2: Command line installation (VS Code or Cursor)
1
code --install-extension path/to/your-extension.vsix
Or for Cursor:
1
cursor --install-extension path/to/your-extension.vsix
Installing from a Remote Repository
GitHub Method
Clone the repo:
1 2 3
git clone https://github.com/username/repo-name.git cd repo-name git checkout branch-name # optional: choose specific branch
Install and package as .vsix: Same steps as described in the local repository section above.
1 2
npm install vsce packageInstall the generated
.vsixfile using one of the methods above.
Alternative: Manual Folder Installation
- Copy your extension folder into the VS Code extensions directory:
- macOS/Linux:
~/.vscode/extensions - Windows:
%USERPROFILE%\.vscode\extensions
- Restart VS Code or Cursor.
Things to Consider
- Version Compatibility: Your extension must match your editor’s API version.
- Dependencies: Unlike Marketplace installs, dependencies must be handled manually.
- No Auto-updates: Manual installations don’t update automatically.
- Development Mode: Use
F5in the extension project to launch a development host for live testing.
These methods give you full control over your development and testing process, ideal for custom or in-progress extensions, whether you’re using standard VS Code or its fork, Cursor.
☕ Support My Work
If you found this post helpful and want to support more content like this, you can buy me a coffee!
Your support helps me continue creating useful articles and tips for fellow developers. Thank you! 🙏