Terminal
Last updated:
The integrated xterm.js terminal inside WebSandbox — running real shell commands inside the WebContainer PTY.
Overview
The terminal gives you full shell access to the virtual environment. You can run npm commands, execute scripts, manage files, and interact with processes exactly as you would in a local terminal — with readline support, colour output, and process signals.
The terminal panel is located in the bottom section of the workspace. It can be expanded to fill the right half of the screen, detached into a floating panel, or collapsed to hide it when not needed.
Available Commands
The workspace environment includes a POSIX-compatible shell with the following tools available out of the box:
node— Node.js runtime (LTS version matching the workspace configuration)npm— package manager (npm 9+)npx— execute npm packages without global install- Standard Unix utilities:
ls,cat,mkdir,rm,cp,mv,grep,find,echo,env git— via isomorphic-git CLI bridge (see Git Integration)
Multiple Terminals
Click the + button in the terminal tab bar to open additional terminal sessions. Each session is an independent PTY process within the same workspace — useful for running a dev server in one terminal while executing commands in another.
Terminal sessions are not persisted across page refreshes. When you re-open a workspace, all running processes are restarted according to the auto-run configuration in workspace settings.
Terminal Shortcuts
| Action | Shortcut |
|---|---|
| Interrupt process (SIGINT) | Ctrl+C |
| Clear terminal | Ctrl+L |
| New terminal tab | Ctrl+Shift+` |
| Scroll up | Shift+PgUp |
| Scroll down | Shift+PgDn |
| Copy selection | Ctrl+Shift+C |
| Paste | Ctrl+Shift+V |
Limitations
- No SSH — outbound SSH connections are not supported. Use HTTPS git remotes instead.
- No raw sockets — tools that require raw TCP/UDP connections to external hosts will not work.
- No GUI applications — applications that require a display server (X11, Wayland) cannot run.
- Package manager limited to npm — yarn and pnpm are supported experimentally; Bun is not yet available.
- No sudo / root — the shell runs as an unprivileged user; operations requiring root privileges are not available.