Delete conversations from the left sidebar

Resolved 💬 4 comments Opened May 21, 2026 by wangshicon Closed May 31, 2026
💡 Likely answer: A maintainer (etraut-openai, contributor) responded on this thread — see the highlighted reply below.

What variant of Codex are you using?

Codex CLI (v0.132.0)

What feature would you like to see?

Problem
The left sidebar lists all past conversations in a flat list, but there is no way to delete or remove old/unwanted conversations from the UI. Over time the list accumulates stale sessions (e.g., quick tests, experiments, abandoned tasks), making it harder to find relevant conversations.

Proposed solution
Add a way to delete a conversation from the left sidebar. Options:

Hover delete button: When hovering over a conversation entry in the sidebar, show a small trash/delete icon (🗑️) on the right edge. Clicking it removes the conversation.
Right-click context menu: Right-clicking a conversation entry shows a menu with "Delete" option.
Keyboard shortcut: With a conversation selected in the sidebar, pressing Delete or Backspace removes it, with a confirmation prompt.
Deleting should:

Remove the entry from session_index.jsonl
Move or delete the corresponding .jsonl file from sessions/YYYY/MM/DD/
Why this matters

Keeps the conversation list clean and organized
Reduces clutter when iterating on many small tasks
Provides a basic data management capability expected in any conversation-based UI
Alternatives considered

Archiving (to archived_sessions/) instead of permanent deletion — could be offered as a secondary option
Bulk select + delete for power users
Additional context
Session data is stored at ~/.codex/session_index.jsonl and ~/.codex/sessions/YYYY/MM/DD/*.jsonl. Currently users must manually edit these files from the terminal to remove conversations.

Additional information

_No response_

View original on GitHub ↗

4 Comments

etraut-openai contributor · 3 months ago

Are you using the Codex app or the CLI? You reported this against the CLI, but there is no "left sidebar" in the CLI.

If you're using the app, you have the option to archive sessions, which removes them from the left panel.

1939869736luosi · 3 months ago

Related follow-up with local verification evidence: #23991

This issue mentions removing the session_index.jsonl entry and corresponding rollout file. I tested the current Codex Desktop archived-chat delete path on macOS: it removed the rollout JSONL and some state DB rows, but the deleted thread ID still remained in session_index.jsonl, logs_2.sqlite, and desktop state after deletion.

Verifier/cleanup tool used for the before/after check: https://github.com/1939869736luosi/codex-sessions-manager

Not suggesting this replace the built-in UI; it is useful for checking what local residues remain after deletion.

wangshicon · 3 months ago

@1939869736luosi The program you gave is very useful, thank you very much.

wangshicon · 3 months ago
Are you using the Codex app or the CLI? You reported this against the CLI, but there is no "left sidebar" in the CLI. If you're using the app, you have the option to archive sessions, which removes them from the left panel.

Yes, I am using the Codex app . After archiving, it can be deleted. Thank you very much.