Codex Desktop silently hides project conversations outside the global recent-50 window
Summary
Codex Desktop currently makes older project conversations effectively disappear from the UI once they fall outside the global recent conversation window. This is not an edge case and it is not just cosmetic: it makes the Desktop app unreliable as a working memory for real projects.
In my daily use, any thread that has not been updated for about a week becomes impossible to find in the Desktop UI. After investigating locally, this is not because the data is deleted. The local session files and SQLite rows are still present. The problem is that Desktop appears to preload only a global recent set of conversations, then groups/searches only that already-loaded subset.
This is a serious UX regression. Users are led to believe their project history has been deleted or lost, while the data is still on disk and visible through lower-level storage/CLI paths. Please prioritize a real fix rather than requiring users to patch bundles, touch rollout mtimes, pin hidden threads, or manually query SQLite.
Environment
- Platform: macOS, arm64
- Codex Desktop observed:
26.429.30905(CFBundleVersion 2345) - CLI observed:
codex-cli 0.125.0 - Date reproduced: 2026-05-05
I also inspected another local Codex app bundle (26.422.21459) and found the same recent-list behavior, so this does not appear to be a one-off local install issue.
Local evidence
Local persisted data is present:
~/.codex/sessions: 2014 rollout JSONL files
~/.codex/session_index.jsonl: 564 entries
~/.codex/state_5.sqlite: 1250 active thread rows
Using a conservative filter for human-visible direct conversations:
where archived = 0
and agent_role is null
and source in ('vscode', 'cli')
I get:
890 direct active local conversations
50 updated within the last 7 days
840 older than 7 days
The cutoff is extremely telling:
rank 50: 2026-04-28 13:13:24 local time
rank 51: 2026-04-27 20:12:58 local time
So the issue looks like "older than a week" only because my last week of usage produced exactly 50 newer conversations. Once a conversation drops from rank 50 to rank 51, it disappears from the Desktop project UI/search even though it still exists locally.
Example project-level impact with private paths redacted:
Project A: 447 active local conversations, 0 in top 50, newest rank 56 -> not findable in Desktop project UI
Project B: 24 active local conversations, 0 in top 50, newest rank 257 -> not findable in Desktop project UI
Project C: 8 active local conversations, 0 in top 50, newest rank 67 -> not findable in Desktop project UI
Telemetry from the Desktop app also matches this failure mode:
thread_count_loaded_recent: 54
while the local database has hundreds of active direct conversations. The extra 4 appear to be pinned/currently loaded threads on top of the hardcoded recent 50.
Code-path evidence from the Desktop bundle
The Desktop app bundle contains this recent-loader behavior:
refetchThreadList(...) {
...
await this.listRecentThreads({ limit: 50 * this.pageCount, cursor: null })
...
}
loadNextThreadListPage(...) {
...
await this.listRecentThreads({ limit: 50, cursor: this.nextCursor })
...
}
searchThreads(...) {
// searches only this.conversationIds, i.e. the loaded recent subset
}
listRecentThreads(...) {
return this.requestClient.sendRequest("thread/list", {
limit,
cursor,
sortKey: this.sortKey,
modelProviders: null,
archived: false,
sourceKinds: ...
})
}
This means the project sidebar is effectively grouping a global recent subset, not loading the actual history for each project/workspace.
Expected behavior
The Desktop UI must not hide valid local project conversations just because they are outside the latest 50 global conversations.
Expected behavior should be:
- When expanding/opening a project, query all local threads for that project/workspace root (
cwd) with pagination. - Sidebar search should query all persisted local threads, not only
recentConversationIdsalready loaded into memory. - The UI should clearly distinguish "no chats" from "older chats not loaded yet". The current behavior is misleading.
- The recent window size should either be much larger or configurable as a temporary mitigation, but increasing 50 to another fixed small number is not the real fix.
- Add a regression test with >50 local conversations across multiple projects where one project has no conversations in the global top 50 but still has valid local history.
Related issues / prior reports
This appears related to, and still reproducible despite, earlier reports:
- openai/codex#15060
- openai/codex#14751
- openai/codex#17540
- openai/codex#18364
Please do not treat this as solved while Desktop still depends on a global recent-50 preload for project history visibility. This bug seriously damages trust in the app because it makes real, persisted work history appear to vanish.
30 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
This is driving me mad, and it's exacerbated by the fact that the companion tasks launched by the plugin are taking up a large amount of the 50 available slots.[ Companion/review jobs should not share the user's main Codex Desktop history feed by default #282
]( https://github.com/openai/codex-plugin-cc/issues/282)
This might actually be the reason. I also did some digging before and found this and was not sure whether this is the case. Especially because the source code of the desktop app is not available, I think. But I also had this 50 sessions limit impression, and this might explain why people complain about things disappearing. So this might actually be a feature, not a bug, but I see it really as a bug, and especially if this is not documented and cannot be changed by users.
It's a feature waiting to happen... a "load more" under older projects or something along those lines would go along way.
I’m seeing what appears to be the same issue on macOS Codex Desktop
0.129.0-alpha.15.A thread is present locally and has the expected title in
~/.codex/session_index.jsonl:019d7348-09ea-76e2-9768-8fd4e3222671REDACTED~/.codex/sessions/2026/04/09/...019d7348...jsonlBut searching Codex Desktop for
REDACTED(exact text from title) does not return it. The search UI instead falls back to unrelated “Recent chats.” (Thread I was looking for was outside of most recent 50 - sat at around #78.)I also checked Codex Desktop app storage under
~/Library/Application Support/Codex; the title/session ID does not appear there, which suggests Desktop search is not querying the full local session archive /session_index.jsonl, only a narrower recent/cache index.Expected: known local sessions with matching titles should appear in Desktop search, even if they are older than the recent chat window.
Actual: matching local session exists on disk but is missing from Desktop search.
I can reproduce what looks like the same issue on macOS with the current Codex Desktop build.
Environment:
26.506.31421,CFBundleVersion 2620codex-cli 0.130.0Darwin 25.4.0 arm64Show = All chats,Sort by = Updated,Organize = Recent projectsObserved behavior:
For one local project, Codex Desktop only shows a small handful of recent chats in the project sidebar, even though many more conversations still exist locally and are visible through lower-level local state / CLI resume flows.
Local evidence:
~/.codex/state_5.sqlitetotal thread rows:1118archived = 0 and agent_role is null:544~/.codex/sessions:930~/.codex/session_index.jsonl:494linesFor the affected project cwd, redacted as
/Users/<user>/code/st_unet_wrfhydro:5734063282025-09-16 09:53:182026-05-12 16:48:595This makes the UI look like it only shows conversations from roughly the last two weeks, but the local data shows that older conversations are still present.
Global recency ranking also matches this issue's suspected failure mode. Among active direct conversations, this project's first relevant rows are at approximately:
126877788182101Counts by global recency window for the same project:
2project conversations7project conversations46project conversations290project conversationsSo this does not look like data loss and does not look like a fixed two-week cutoff. It looks like Codex Desktop is still grouping/searching only conversations that have already been loaded from a global recent window, instead of querying/paginating all conversations for the selected project cwd.
Expected behavior:
When a project is shown in the sidebar and
Show = All chatsis selected, expanding/searching that project should be able to discover all persisted local conversations for that project cwd, with pagination if needed. The UI should not make older valid project conversations appear to be gone just because they are outside the currently loaded global recent set.I’m seeing this again on Codex Desktop 26.506.31421 (bundle 2620), macOS 26.5 arm64, codex-cli 0.128.0.
Concrete repro/evidence:
0vscode~/.codex/sessions/...~/.codex/session_index.jsonlcontains the same thread id/title~/.codex/state_5.sqlitecontains the thread rowNo matches.Expected: sidebar search should search persisted local thread storage, not only currently loaded/recent sidebar items. If a thread exists in
state_5.sqlite, is unarchived, and has a valid rollout file/session index entry, exact-title search should find it.One clarification: this is not only a search bug. The missing thread was also not visible in the normal Chats sidebar.
Search appears to fail because it only searches the loaded sidebar/recent subset. The higher-level issue is that valid unarchived local chats outside that subset are not visible or discoverable in the Desktop UI at all.
After hours of tracking down the cause for my threads disappearing I came across this bug report that most likely explains it, since I can also "recover" threads from the CLI by "touching" them. But obviously this is not a solution.
This limitation has serious implications. Probably it was introduced for a reason (performance?), but a better solution should be a priority. For a short-term fix, at least a config setting should be introduced that allows the history limit to be changed manually.
I actually spent my precious Codex quota debugging this bug. WTF
I can add a Windows Codex Desktop reproduction with a concrete local workaround that confirms this is a finite global recent-window problem, not data loss.
Environment:
26.519.5221.0%USERPROFILE%\.codex\state_5.sqlite%USERPROFILE%\.codex\.codex-global-state.json%USERPROFILE%\.codex\session_index.jsonl%USERPROFILE%\.codex\sessions\...\rollout-*.jsonlObserved behavior:
No chats/ incomplete chat lists.state_5.sqlitehad live, unarchived thread rows and all matching rollout JSONL files existed.Concrete project A:
13136/13were inside the global rollout-file mtime top-50 window.Workaround test:
LastWriteTimeUtcon the 7 missing project rollout JSONL files.13/13project threads in the global rollout-mtime top-50 window.Concrete project B:
3389,90,93No chatsfor that project.Global diagnostic on the same machine:
11211223750threads in the global top-50:11Important secondary finding:
touch/mtime promotion is only a workaround that redistributes the limited 50 visible slots. It is not a real fix for local history visibility.Expected behavior:
cwd/ workspace root from durable local state.Actual behavior:
No chatseven though their local threads and rollout files exist.Suggested fix direction:
cwdwith pagination.No chatswhen local state contains matching live threads outside the global recent window.I can reproduce this on macOS with Codex Desktop
26.519.41501.The affected project has multiple existing local conversations, but the Desktop sidebar shows the project as empty.
The behavior appears tied to the hardcoded global recent-thread window:
limit=50does not include any conversations from the affected project.limit=100includes the missing project conversations.This makes the project appear to have no chats even though the conversations still exist and can be recovered through lower-level local state / direct thread lookup.
The main problem is that this limit does not seem configurable.
50may be reasonable for the initial global recent list, but it is not reasonable as the effective visibility boundary for project history.Expected behavior:
Adding another macOS reproduction on a newer Codex Desktop build, with paths/project names/thread IDs redacted.
Environment:
26.519.41501(CFBundleVersion 3044)~/.codex/state_5.sqlite,~/.codex/session_index.jsonl,~/.codex/sessions/.../rollout-*.jsonlObserved behavior:
threads.titlewas the full first user message, so the visible title would be a long truncated prompt rather than a short generated title.Local evidence, redacted:
The top of the project-local ordering looked like:
So this was not data loss. The local SQLite row, session index entry, and rollout file all existed. The issue was that the pinned project sidebar only exposed a small recent subset, making valid project history appear missing.
I also found a related metadata problem in the same repro:
That meant even if the row surfaced elsewhere, the UI title could be an unhelpful/truncated first prompt rather than a recognizable short title. Manually normalizing only the local title metadata made the chat easier to identify, but it does not address the core visibility problem.
Expected behavior:
threads.title = first_user_messagerows should not degrade discoverability; Desktop should derive/store a short usable title or fall back gracefully.This reproduces the same class of bug as this issue: valid local project history exists, but Desktop UI presentation makes it appear missing.
I have a current macOS reproduction that matches this failure mode and adds a pinned-thread angle.
Environment:
26.519.81530(CFBundleVersion 3178)26.5(25F71), arm64Observed:
Local evidence, with project path redacted:
The important recent-window signal:
So the affected thread is just outside the apparent global recent-50 window, even though it is a valid unarchived user thread whose
cwdexactly matches the project.Pinned state detail:
The user remembers pinning this thread from the MacBook Pro controller, and also reports that several pinned threads may have disappeared. I cannot prove from local state whether the pin was lost, overwritten, or never persisted, but the end result is that a still-existing unarchived project thread is absent from the UI and the pinned list.
This appears to be the same sidebar/history loading problem described here, with an additional symptom that pinned state may not protect a thread from disappearing or may itself be getting lost in a remote-control setup.
I can confirm this on another Codex Desktop setup, triggered after using "Imported agent setup". In our case the failure happened in two stages, and the second stage matches this issue very closely.
Environment:
26.527.313260.130.0~/.codex/state_5.sqliteand~/.codex/sessions/...Stage 1: external-agent import timestamp collapse
created_at/updated_at, instead of their original conversation timestamps.Durable local workaround for stage 1:
session_metatimestamp / payload timestamp to the original first-message time.threads.created_at,threads.updated_at,created_at_ms, andupdated_at_msto match.After that, imported Claude Code chats and native Codex chats were chronologically interleaved again in Recents.
Stage 2: project sidebar still showed
No chatsAfter fixing the import timestamps, several saved project folders still showed
No chats, even though direct local inspection andthread/listbycwdreturned matching native Codex threads.Our local evidence matches this issue:
thread_count_loaded_recent=54.123,205,211,234,235, and268.thread-workspace-root-hints,thread-project-assignments,sidebar-project-thread-orders, andpinned-project-idsdid not restore the project groups.updated_at/updated_at_msso it ranked near the top made that project group immediately show the chat.1-40restored the missing project groups.That strongly supports the hypothesis here:
The Desktop sidebar has saved project roots, but fills project group
threadKeysonly from the currently hydrated global Recent conversation cache. If a project has no threads inside that cache, the project row still renders but appears asNo chats.Suggested fix:
When rendering or expanding a saved local project group, Desktop should lazily hydrate that project's threads with
thread/listscoped bycwd/ workspace root, with pagination. The UI should not inferNo chatsfrom an empty global Recent subset.Related import-specific issue: #21376
Written by Codex
Adding another current macOS reproduction on Codex Desktop
26.527.31326/ bundle3390with bundledcodex-cli 0.135.0-alpha.1. This one includes a local bundle workaround that confirms the issue is the renderer's finite global recent hydration window, not missing local thread data.Environment:
26.527.31326(CFBundleVersion 3390)codex-cli 0.135.0-alpha.1Observed:
No chats/ no visible chat items..codex-global-state.jsonunder saved/project order state and is not marked projectless.source='vscode'threads for thatcwd.thread/turns/listreturns turn data, so the chats are readable by the app-server.Exact app-server signal:
returned no threads for the affected project. The same request with
limit: 100returned both project threads at global ranks87and94.That matches the failure mode described here: the project page/sidebar groups from the globally hydrated recent conversation subset. If a project has no conversations in that subset, the project can render as empty even though durable local state contains valid unarchived threads.
Local workaround that confirmed the cause:
recentConversationPageCount=1torecentConversationPageCount=3inside/Applications/Codex.app/Contents/Resources/app.asar.50 * recentConversationPageCount, so it hydrates 150 recent threads instead of 50.This is not a recommended user workaround because it modifies a signed app bundle and will be overwritten by updates. It is useful as a confirmation that the data is present and the visibility bug is in Desktop hydration/project grouping.
Proposed product fix:
thread/listquery using that workspace root /cwd, with cursor pagination.No chatsuntil a project-scoped fetch has completed and returned no rows. Ideally show a load-more affordance orshowing N of Mstyle state.Written by Codex.
I am having the same issue as others. While I understand the UI limitation of showing endless past chats, I do not understand the search only searching that limited group of chats. I have long running chats, for projects developing over time and am also experiencing them dissapearing before project completion.
I do use the archive function alot, so I do need to have more than the shown list accessable.
It seems weird to need a Codex chat to find, and reactivate past chats, although annoyingly that process prematurely is hiding a different active chat.
Could OpenAi in it own development not just ask Codex to add a "Show all" option that replaces the active chat with a list of all active chats in that project.
Eg at the end of the cuurent shown project chat list change the options to
Show More / Show All
or
Show Less / Show All
It's hardly complicated to do, but will but make the software so much more useful. It took me a while to realise my chats weren't just being lost, causing unnecassary distress which I am sure is happening to many people especially the more casual user
Retracted. I opened a separate standalone issue for this report instead: #25761
Adding one more macOS data point, mostly for the search/open path rather than data loss.
Environment:
26.601.21317(CFBundleVersion 3511)What happened:
Fix Atlas PDF extensionwas difficult to reopen from search/history: clicking the search result did not open the thread.~/.codex/state_5.sqlitehad an unarchivedsource='vscode',thread_source='user'row for the thread.~/.codex/sessions/2026/05/15/....~/.codex/session_index.jsonlcontained the same title/thread id.Why I think this belongs here:
Expected:
Hi everyone, I'm tracking the same Codex Desktop missing-thread/sidebar-history issue on macOS.
For those affected here: did you eventually get all hidden project threads back in Desktop? If yes, what exact method worked durably for you?
Examples I'm trying to distinguish:
codex resume --all <thread-id>rehydrated itsession_index.jsonl/state_5.sqlite/.codex-global-state.jsonfixed itlistAllThreadspatch fixed itIn my case, the missing project threads still exist in
~/.codex/sessionsandstate_5.sqlite, but Desktop does not hydrate them back into the project sidebar after restart. Any confirmed durable fix would help. Please do not share private session contents; sanitized method/results are enough.I’m seeing this too on Codex Desktop macOS.
Local evidence:
~/.codex/state_5.sqlitehas 11,621 thread rows.But Codex Desktop / thread search did not find known older titles that exist locally. Recent threads search fine.
The failure mode is that older conversations feel deleted or inaccessible from the UI, even though the local DB still has them. I eventually found them through terminal/SQLite, but it took a lot of fighting.
Expected: sidebar/search should query the full local thread index, or at least expose archived/older results clearly.
Actual: UI appears limited to a recent loaded/indexed window.
My patch here is :
Patch
/Applications/Codex.app/Contents/Resources/app.asar: replace the single byte stringlet t=await this.listRecentThreads({limit:50*this.recentConversationPageCount,cursor:null});with same-lengthlet t={data:await this.listAllThreads({modelProviders:null,archived:!1}),nextCursor:null};, after backing up the original ASAR.`Then fully quit and reopen Codex.
50 Convo really isn't much, Incredible how long it takes to fix this major issue.
Adding a macOS datapoint after updating to the latest Desktop build.
Environment:
~/.codexRecovery status on my affected project:
state_5.sqlitestill has 251 active/non-archived rows with the expected project cwd.~/.codex/sessions.So my current result is: 26.608.12217 looks like a partial recovery, not a full recovery. This still appears consistent with an incomplete sidebar/project-history reindex rather than data loss.
Adding another macOS datapoint that matches the current behavior reported above.
Environment:
~/.codexObserved behavior:
Local evidence:
~/.codex/sessionsstill contains 415 rollout JSONL files.~/.codex/archived_sessionscontains 13 archived rollout JSONL files.~/.codex/state_5.sqliteis readable and passespragma integrity_check.threadstable still contains the expected local thread records.thread_sourcevalues forsource='vscode'rows tothread_source='user', then ran a WAL checkpoint and fully restarted the app.Current shape:
updated_at, and older project conversations remain hidden from the sidebar even though they still exist instate_5.sqliteand the rollout files.This looks consistent with the remaining global recent-window / incomplete project-history reindex issue rather than actual data loss. It would be helpful to have an official full local reindex/recovery command that rebuilds Desktop sidebar/project history from durable local state.
I think this may be fixed with the latest release?
@peterpeirce yes it has been fixed in the latest update.
There are still hidden threads on my end in project, dont think its fixed. Can anyone else verify?
The UI list should be backed by a project-scoped session index, not a filtered recent-global window. Store project key, git root/cwd, thread id, title, updated_at, archived/pinned state, and index status. Search should query that index directly and report skipped/corrupt rows, so old project history looks stale only when the data is actually missing.
---
_Generated with ax._
Hi @ashe0047 asked if other people were having similar issues. I certainly have had the full thread show and now can see more of my active threads, but I am still experiencing a few issues still. Threads seems to randomly disappear. I can not work out if this is due to incorrectly sorting, or some other random issue.
Threads on my desktop computer have reappeared but they don't realiably show if access via the mobile app, even new chats.
I think this all is working better but not fixed. Mobile seems worse, but I hardly use that so it's hard to be specific about what is normal vs broken
The conversation list in sidebar seems to have been fixed in the latest version on macos Codex app as I can see all the conversations for each of my project now but i cannot confirm for mobile Codex. The last time i checked, the conversation list in codex mobile is indeed a mess