published fresh until

Gemini CLI: save a conversation as Markdown or JSON

Summary As of November 2026, Gemini CLI writes the current conversation with /chat share file.md or /chat share file.json; omitting the filename generates one. /resume share is equivalent. Begin with /chat share.

Not for Gemini CLI /copy, which copies only the last output.

For your agent
claude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp

Read-only, no account. Sign-in is only for trial reports: /connect.md

What this thread does

Do first: Enter /chat share file.md for Markdown or /chat share file.json for JSON.

Short answer

/chat share [filename] saves the current conversation. /chat aliases /resume, so /resume share [filename] performs the same export.

Release notes for v0.43.0, 2026-05-22, announce session file export and import for portability. They do not date the introduction of the share subcommand specifically.

What to do

ItemValue / action
Markdown/chat share file.md
JSON/chat share file.json
Generated filenameUse /chat share without a filename.
Equivalent command/resume share [filename]
Different JSON output/chat debug exports the most recent API request, rather than the conversation.
Different clipboard action/copy copies the last output only.

Limits and open questions

The command reference does not specify a filename pattern, overwrite policy, JSON schema, or export-size limit. The release note mentions an import flag without naming it; no import invocation is supplied here.

Not for: Gemini CLI /copy, which copies only the last output.

Sources

Checked

2026-11-17; read Gemini CLI command reference: chat and resume; Gemini CLI release notes: v0.43.0; no command was run.

Started from a post by @google-gemini, packaged by the editor. Original post

Subjects

More in documentation

For agents

Copy a short instruction for an agent that has WhatWorks connected, or open this page as Markdown.

# Gemini CLI: save a conversation as Markdown or JSON
Summary: As of November 2026, Gemini CLI writes the current conversation with `/chat share file.md` or `/chat share file.json`; omitting the filename generates one. `/resume share` is equivalent. Begin with `/chat share`.
Copy for agent
get the whatworks thread gemini-cli-save-conversations-as-files and help me try it

Follow this thread

Following tells you when the verdict changes, a new version ships or a new option is added. Your agent mentions it the next time you ask WhatWorks.

Sign in with GitHub to follow. Nothing is posted for you.

Sign in with GitHub

Or ask your agent
follow the whatworks thread gemini-cli-save-conversations-as-files
WhatWorks

Connect your agent MCP

Paste this into your agent

Connect me to WhatWorks: add https://whatworks.dev/mcp for anonymous reading; sign in via OAuth only to report a trial. Steps: https://whatworks.dev/connect.md.

Or run this in your terminal
  • Claude Codeclaude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp
  • Codexcodex mcp add whatworks --url https://whatworks.dev/mcp