Skip to content
groundedby
Waitlist

Copilot CLI

Where GitHub Copilot CLI stores your session history

Copilot CLI keeps sessions in ~/.copilot/session-state and syncs them to your GitHub account by default. Where they are, how to export them and how to stop the sync.

Updated October 29, 2026 // Markdown

Quick factsas of October 2026 (v1.0.105)
Made by
GitHub
History lives in
  • All~/.copilot/session-state/<session-id>/events.jsonl
  • Search index~/.copilot/session-store.db
Format
JSONL events plus YAML and Markdown files per session
Kept for
No automatic expiry documented
Resume
copilot --resume, copilot --continue
Cloud copy
Synced to your GitHub account by default (remoteExport)

GitHub Copilot CLI, the copilot command, stores each session in its own folder. It differs from most agents in one way that matters: by default it syncs sessions to your GitHub account.

Where the files are

~/.copilot/
├── session-state/
│   └── <session-id>/
│       ├── events.jsonl       # the session, as a stream of events
│       ├── workspace.yaml
│       ├── plan.md
│       ├── checkpoints/
│       └── files/
├── session-store.db           # SQLite index used for search
├── command-history-state/
└── settings.json

Versions before 0.0.342 used history-session-state/. COPILOT_HOME moves the whole folder. The events.jsonl schema is not documented.

Turn off the cloud sync

In ~/.copilot/settings.json:

{
  "remoteExport": false
}

Or for a single run: copilot --sync-session=off. On Copilot Business and Enterprise, the organization policy "Store local sessions in the Cloud" controls this.

Resume and export

copilot --resume             # pick a session
copilot --resume=<id|name>
copilot --continue           # the latest

Inside a session, /resume switches sessions and /share (also /export) writes the session to a file, HTML or a gist. --share=PATH does it at the end of a non-interactive run.

Delete history

/session delete [ID] removes one session and /session delete-all removes them all. Turn off sync first if you do not want a copy kept on GitHub.

Privacy notes

  • Synced sessions sit in your GitHub account, alongside your code.
  • Local files include command output and file contents. Redact before sharing.

The groundedby evaluator does not read Copilot CLI sessions yet.

Questions

Does Copilot CLI upload my sessions?+

By default, yes - sessions sync to your GitHub account. Set remoteExport to false in ~/.copilot/settings.json to stop it, or run with --sync-session=off. On Business and Enterprise plans an organization policy, "Store local sessions in the Cloud", decides.

Where are Copilot CLI sessions on disk?+

In ~/.copilot/session-state, one folder per session holding events.jsonl, workspace.yaml, plan.md, checkpoints and files. COPILOT_HOME moves the folder.

Is this the same as gh copilot?+

No. The gh copilot extension was retired in October 2025. Copilot CLI is the copilot command.

Sources

  1. GitHub docs, Copilot CLI config directory reference
  2. github/copilot-cli changelog

Waitlist

Your sessions, your call.

We are building an opt-in marketplace where developers license redacted sessions they pick, one by one. Join to hear first.

Your email and the side you picked. Nothing else. Privacy