Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>WSL Path CopierNew to Visual Studio Code? Get it now.
WSL Path Copier

WSL Path Copier

asiball

|
1 install
| (0) | Free
Copy WSL files and folders as Windows paths.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

WSL Path Copier

Copy a file or folder open through Remote - WSL as a Windows path.

This converts in the WSL → Windows direction, so you can paste the path into Windows apps such as File Explorer. Many other extensions convert the other way, from Windows paths to /mnt/c/....

Use

  • In the Explorer, right-click a file or folder and select WSL Path: Copy Windows Path. If several items are selected, all of their paths are copied, one per line.
  • With an editor open, run WSL Path: Copy Windows Path from the Command Palette.

No keybinding is assigned by default. To add one, open Preferences: Open Keyboard Shortcuts (JSON) and add an entry such as:

{
  "key": "ctrl+alt+c",
  "command": "vscode-wslpath.copyWindowsPath",
  "when": "editorTextFocus && remoteName == wsl"
}

The extension runs wslpath -w in the WSL extension host, then copies the resulting path through the VS Code clipboard API. For example, /mnt/c/work/example becomes C:\work\example; paths in the WSL filesystem are typically copied as \\wsl.localhost\<distribution>\....

The command is shown only in a Remote - WSL window.

Development

npm install
npm run compile

Use Run Extension in VS Code to launch an Extension Development Host connected to WSL.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft