session_stop
Stop a session and keep it.
Saves the session exactly as it is (every tab with its history, and the files in /workspace), frees its machine and stops billing. A stopped session is free. It is kept for your plan’s retention days, then deleted.
Inputs
| Name | Type | Default | Allowed values | Description |
|---|---|---|---|---|
sessionIdrequired | string | – | – | The session's id, from session_create. |
sessionId is the id that session_create returned. The server keeps no default session. This tool works on the session as it is, running or stopped, and does not resume it first.
Example call
This is what an MCP client sends. You do not write it yourself: ask the model in plain words and it calls the tool.
{ "name": "session_stop", "arguments": { "sessionId": "6c1f3c9e-1d2a-4f67-9b0e-1b2c3d4e5f60" }}What it returns
A confirmation line with the day the session will be deleted.
Session 6c1f3c9e-1d2a-4f67-9b0e-1b2c3d4e5f60 stopped. It is kept until 2026-11-04T10:00:00.000Z; session_resume brings it back.When a call fails, the result is marked as an error. Its text starts with the API’s error code, such as unauthorized or session_not_running, followed by its message.
Annotations
The server tells every client what this tool does to the world, so a client can decide what to ask you about before it runs.
| Annotation | Value |
|---|---|
title | Stop a session |
readOnlyHint | false |
destructiveHint | false |
openWorldHint | false |
Good to know
- Running processes and page memory are not saved: commands that were running stop, and pages reload when the session is resumed.
- A stopped session keeps its browser, files, recording and logs for your plan’s retention days (7 on Free, 30 on Hobby and Startup, 90 on Scale). Then it is deleted.
- To remove it now, with its recording and logs, use session_delete.
The same thing with the API
| Endpoint | Reference |
|---|---|
POST /v1/sessions/{id}/stop | Stop a session |
These docs describe a beta API. Endpoints, fields and SDK methods may change before general availability; breaking changes will be listed in the changelog.