Running VSCodium in Portable Mode on a USB Drive
Learn how to run VSCodium from a USB stick without leaving any settings, extensions, or cache on the host computer, and understand the trade‑offs of portable mode.
14 May 2026, 04:02 UTC

Problem: needing a clean editor on shared or public computers
When you work on a lab machine, a coworker’s PC, or any system you don’t control, installing a full editor can leave behind settings, extensions, and cache files. Even if you uninstall the program, remnants often remain in the user profile directory, which may violate privacy policies or simply clutter the host.
Thesis: VSCodium’s portable mode keeps all user data alongside the executable
VSCodium, the community‑built binary of VS Code, offers a portable mode that stores the User folder, extensions, and caches in a data directory placed next to the editor’s executable. No data is written to the host’s %APPDATA% (Windows) or ~/Library/Application Support (macOS/Linux) unless you explicitly opt‑in, making it safe to run from a USB stick or any removable folder.
How portable mode works
When VSCodium starts, it looks for a folder named data in the same directory as the binary. If the folder exists, the editor uses it as the user‑data directory; if not, it creates one automatically. This behavior is equivalent to launching the program with the --user-data-dir flag pointing to that folder, but the flag is optional when the folder follows the naming convention.
The data folder contains subfolders that mirror a standard VS Code installation:
User– storessettings.json, keybindings, snippets, and global state.extensions– each installed extension is unpacked here.cachedDataandCachedExtensionVSIXs– runtime caches and downloaded VSIX files.
Because all of these live on the removable medium, ejecting the drive leaves no trace on the host system.
Worked example: setting up and verifying portable mode
Where to run the commands: a command prompt (Windows) or terminal (macOS/Linux) with normal user privileges; no administrator rights are required.
Placeholders: replace /path/to/vscodium with the actual folder containing the VSCodium executable.
- Download the latest VSCodium release for your platform and extract it to a folder on your USB drive, e.g.
E:\VSCodium(Windows) or/Volumes/USB/VSCodium(macOS). - Verify that the executable is present:
VSCodium.exe(Windows) orVSCodium(macOS/Linux). - Create an empty folder named
datanext to the executable. On Windows you can run:
mkdir E:\VSCodium\data
On macOS/Linux:
mkdir /Volumes/USB/VSCodium/data
- Launch the editor. On Windows double‑click
VSCodium.exeor run:
E:\VSCodium\VSCodium.exe
On macOS/Linux:
/Volumes/USB/VSCodium/VSCodium
The first start will populate the data folder with the subfolders mentioned above.
- Install an extension to test persistence. Open the Extensions view (Ctrl+Shift+X) and install, for example, the “Prettier - Code formatter” extension.
- After installation, close VSCodium.
- Eject the USB drive safely.
- Insert the drive into a different computer and launch VSCodium from the same folder.
- Open the Extensions view; you should see Prettier already installed and your user settings (if you changed any) present.
Expected checks: after step 5, browse the data folder and confirm the existence of data\User\settings.json (or the platform‑equivalent path) and data\extensions\esbenp.prettier-vscode\.
Relevant risks: if you mistype the --user-data-dir flag or accidentally point to a host folder, VSCodium will write data there instead of the USB drive. Always verify that the data folder resides on the removable medium before launching.
Trade‑offs and limitations
While portable mode offers isolation, there are practical considerations:
- Performance: running from a USB 2.0 drive can be noticeably slower, especially when loading large extensions or the bundled Node.js runtime. USB 3.0 or better mitigates this.
- OS integration: because the editor is not installed system‑wide, file‑association handlers (e.g., opening a
.jsfile by double‑clicking) may not launch the portable VSCodium. You must open files from within the editor or create a custom shortcut. - Updates: portable mode does not auto‑update. When a new VSCodium release appears, you must replace the entire executable folder on the drive and copy your existing
datafolder over to preserve settings and extensions. - Policy restrictions: some organizations block execution from removable media. In such environments you may need administrator approval or rely on a network‑based portable solution.
Actionable closing: verify and maintain your portable setup
To ensure your portable VSCodium remains trustworthy, adopt this quick checklist after each use:
- Confirm that the
datafolder is still located next to the executable on the USB drive. - Check the host’s user‑data locations (
%APPDATA%or~/Library/Application Support) for any newly createdVSCodiumorvscodiumfolders; they should be absent. - Periodically run a process‑monitoring tool (e.g., Process Explorer on Windows or
fs_usageon macOS) while the editor is running to verify that no file writes occur outside thedatadirectory. - When a new Vscodium version is released, download the release, replace the old binaries, and copy the existing
datafolder into the new directory to retain your configuration.
By following these steps you can enjoy a full‑featured editor on any machine without leaving behind unwanted traces, while being aware of the performance and maintenance trade‑offs inherent to portable execution.
0 replies
A thoughtful contribution can make all the difference. Be the first to share one.