VS Code for the web is the full VS Code editor running in a browser tab, with nothing to install. Open https://vscode.dev for a blank editor, or press . on any GitHub repository to open it in github.dev.
It edits files and works with Git, but it has no terminal and no debugger. This article covers the ways to open it, what you can and can't do, and what to use when you need to run code.
How to open VS Code in the browser
There are three entry points, and they all load the same web editor.
| Entry point | How to open it | Good for |
|---|---|---|
| vscode.dev | Go to https://vscode.dev | Local files, or any repo from a link |
| vscode.dev with a GitHub repo | https://vscode.dev/github/<organization>/<repo> | Opening a specific GitHub repo |
| github.dev | Press . on a repo or pull request, or change github.com to github.dev in the address bar | Quick edits and commits from GitHub |
| vscode.dev with Azure Repos | https://vscode.dev/azurerepos/<organization>/<project>/<repo> | Azure DevOps repos |
The example in Microsoft's documentation is https://vscode.dev/github/microsoft/vscode.
Open a repository on github.dev
While you browse a repository or pull request on GitHub, press . to open it in the same tab. Press > to open it in a new tab. You can also open the edit dropdown while viewing a file and choose github.dev. You must be signed in to GitHub.
github.dev does not clone the repository. According to GitHub's documentation, your work is saved in the browser's local storage until you commit it, so commit regularly.
To commit from github.dev:
- Open the Source Control view in the Activity Bar.
- Click the plus icon next to a changed file, or next to Changes to stage everything.
- Type a commit message.
- Click Commit & Push. The changes go straight to your branch on GitHub.
To open a pull request, click the pull request icon at the top of the Source Control side bar, check the branches, add a title and description, and click Create. If you are working on an existing pull request, committing sends the changes to that pull request's branch, so no separate push step is needed.
Open local files and folders in vscode.dev
vscode.dev can work with code on your own machine. Use File > New File from the Command Palette (F1) to create a file.
Opening a whole folder depends on your browser. Folders can only be opened locally in browsers that support the File System API. The documentation names Edge and Chrome as supporting it today. In a browser without it, you cannot open a folder, but you can open individual files instead.
What does not work in VS Code for the web
- No terminal and no debugger. The documentation states "the terminal and debugger are not available."
- No compiling or running. You cannot compile, run or debug code such as Rust or Go in the browser sandbox. GitHub's documentation says the same about github.dev: there is no compute, so you cannot build and run your code.
- Only some extensions. Only a subset of extensions can run in the browser. These are called web extensions: extensions specifically created or updated to run on the web. An extension that cannot run shows a warning icon and a Learn Why link.
- Browser version. The documentation lists the latest versions of Chrome, Edge, Firefox and Safari. Older versions may not work.
Practically, this makes the web editor a good fit for reading code, fixing a typo, editing Markdown or config files, reviewing a pull request and making a small commit. It is a poor fit for anything that needs a build step, a test run or a language server that depends on a local runtime.
Install extensions in the web editor
Use the Extensions view as you would on the desktop. Compatible web extensions appear there and can be installed. Installed extensions are saved in the browser's local storage. To carry your extensions across browsers, instances and the desktop app, turn on Settings Sync.
How to run code: Codespaces, tunnels or the desktop app
When you hit the limits above, the documentation points to three options:
- GitHub Codespaces. A dedicated cloud VM with a working terminal for running and debugging. GitHub's comparison: github.dev is free and opens immediately, while Codespaces assigns a VM and configures a container from
devcontainer.json, which can take a few minutes. Codespaces supports most Visual Studio Code Marketplace extensions and has a free monthly usage quota for personal accounts. From the web editor, Continue Working On... can create a codespace, which needs the GitHub Codespaces extension and permission to create codespaces. - Remote Tunnels. You connect the web editor to another machine, such as a desktop PC or a VM, without SSH. Your code and runtimes stay on that machine.
- VS Code on the desktop. Continue Working On... can also clone the repo and reopen it on the desktop.
Use vscode.dev with your own machine through a tunnel
Run this on the remote machine:
code tunnel
The command downloads and starts the VS Code Server on that machine and then creates a tunnel to it. The first time, you are prompted to accept the server license terms; the --accept-server-license-terms flag skips that prompt. The CLI is built into VS Code Desktop. For a standalone or terminal-only install, use ./code instead of code.
The CLI prints a URL tied to that machine, in the form https://vscode.dev/tunnel/<machine_name>/<folder_name>. Open it in any browser. The first time from a given client, you are asked to log in with GitHub. Microsoft's security notes say hosting and connecting both require authentication with the same GitHub or Microsoft account on each end.
With a tunnel, the terminal and debugger work, because the code runs on the remote machine and the browser is only the interface. The tunnel is reachable only while VS Code is still running there. To keep a CLI tunnel alive, use code tunnel service install or code tunnel --no-sleep. Press Ctrl+C to end it.
Is this the same as the desktop app?
It is the same editor interface, but not the same capabilities. The desktop app has the integrated terminal, the debugger and the full extension catalog. If you are unsure which edition suits you, see VS Code vs Visual Studio, or VSCodium vs VS Code for the open-source build. Once you are on the desktop, the VS Code terminal guide covers the feature the web version lacks.
If it does not open or behave as expected
- The . key does nothing. The shortcut works while you browse a repository or pull request, and you must be signed in to GitHub. Otherwise, change
github.comtogithub.devin the address bar. - "Open Folder" is missing or fails. Your browser probably lacks File System API support. Use Edge or Chrome, or open single files.
- An extension is greyed out with a warning icon. It is not a web extension. Click Learn Why, or use the desktop app or a codespace.
- Edits seem to have disappeared. Unsaved work lives in the browser's local storage. Clearing site data removes it, so commit or save before you do.
Frequently asked questions
- Is VS Code for the web free?
- Yes. vscode.dev and github.dev are free to use. github.dev requires you to be signed in to GitHub. GitHub Codespaces, the full cloud development environment, is a separate product with a free monthly usage quota for personal accounts.
- Can I run code in VS Code for the web?
- No. Microsoft's documentation says the terminal and debugger are not available, and you cannot compile, run or debug code such as Rust or Go in the browser. To run code, use VS Code on the desktop, GitHub Codespaces or a Remote Tunnel to a machine you control.
- Does VS Code for the web work offline?
- The documentation does not describe an offline mode. The editor is loaded from vscode.dev or github.dev, so plan on needing a connection to open it. Changes you make are kept in the browser's local storage, which is why you should commit or save them promptly.
- Which browsers can open a local folder in vscode.dev?
- Folders can only be opened locally in browsers that support the File System API. As of the VS Code documentation, that means Edge and Chrome. In other browsers you cannot open a folder from your computer, but you can open individual files.