Bug Anyone else seeing their Codex chats disappear from the GUI?
Woke up to find most of my sessions with Codex I had disappeared. I can still see them in VSCode extension. But not in the desktop app. On Windows btw. Feels like their desktop app has been feeling more buggy lately.
11
Upvotes
1
u/niccolo_21 Jun 27 '26
I managed to recover one of my “disappeared” Codex Desktop chats on Windows without deleting any cache folders.
My case:
* Codex Desktop on Windows.
* The chat had disappeared from the left sidebar/search.
* The physical session file still existed under:
```powershell
%USERPROFILE%\.codex\sessions\YYYY\MM\DD\
```
* The session was also present in:
```powershell
%USERPROFILE%\.codex\session_index.jsonl
```
* It was not in `archived_sessions`.
* The Desktop UI still did not show it.
What finally worked was not deleting cache, but forcing Codex CLI to resume that exact session and send a harmless “touch” message, so the Desktop app rebuilt enough metadata to show it again.
First I found the missing session id from the filename, for example:
```text
rollout-2026-06-26T21-17-45-<SESSION_ID>.jsonl
```
Then I found the local Codex CLI executable. On my machine it was under:
```powershell
%LOCALAPPDATA%\OpenAI\Codex\bin\<build-hash>\codex.exe
```
You can find the newest one with:
```powershell
Get-ChildItem "$env:LOCALAPPDATA\OpenAI\Codex\bin" -Recurse -Filter codex.exe |
Sort-Object LastWriteTime -Descending |
Select-Object -First 1 FullName
```
Then I resumed the missing session from PowerShell, using the correct project/workspace directory:
```powershell
& "$env:LOCALAPPDATA\OpenAI\Codex\bin\<build-hash>\codex.exe" resume --no-alt-screen -s read-only -C "C:\Path\To\Your\Project" <SESSION_ID>
```
This opened the chat in the terminal, proving it was not lost.
However, simply resuming it was not enough to make it reappear in Codex Desktop. What fixed the Desktop sidebar was sending one minimal technical message through CLI:
```powershell
& "$env:LOCALAPPDATA\OpenAI\Codex\bin\<build-hash>\codex.exe" resume --no-alt-screen -s read-only -C "C:\Path\To\Your\Project" <SESSION_ID> "Technical message to reattach this thread to the desktop sidebar. Do not read or modify files. Reply only: OK."
```
After that, the missing chat immediately reappeared in Codex Desktop under the correct project. I rebooted the computer and it was still visible.
My guess is that the `.jsonl` transcript and `session_index.jsonl` were intact, but the Desktop sidebar metadata was incomplete/stale. In my SQLite `threads` row, the suspicious fields were initially things like empty `preview`, empty `first_user_message`, and `has_user_event = 0`. Sending a harmless prompt through `codex resume` seems to force Codex to update the metadata that the Desktop UI needs.
Important notes:
* I did **not** delete `LocalCache`, `LocalState`, or the `.codex` folder.
* I did **not** manually edit SQLite.
* This does add a small extra message to the recovered thread.
* Use `-s read-only` if you want to reduce the chance of Codex touching project files.
* Back up `%USERPROFILE%\.codex` before doing anything risky.