Add ability to update/migrate thread references when projects are moved to new locations

Open 💬 19 comments Opened Feb 7, 2026 by becerra-alberto
💡 Likely answer: A maintainer (github-actions[bot], contributor) responded on this thread — see the highlighted reply below.

What variant of Codex are you using?

Codex App

What feature would you like to see?

Problem

Currently, when a project folder is moved to a new location, all existing conversation threads associated with that project become inaccessible. The Codex App displays the error message "This project folder was deleted or moved" because the thread references are hardcoded to the original file path.

This is a common workflow - users frequently reorganize their project folders. As noted by the Codex team (issue #11019), threads are stored in an internal database with absolute file path references, making them vulnerable to breakage on relocation.

Proposed Solution

Add a feature that allows users to update or migrate thread references when a project has been moved. Some possible implementations:

Option 1: Automatic Detection & Migration

When opening Codex App, detect if a previously-indexed project has been moved and automatically offer to update the thread references to the new location.

Option 2: Manual Path Update Dialog

Add a "Project Path Changed" dialog that appears when a broken project is accessed, allowing users to:

  • Browse to the project's new location
  • Confirm the update
  • Migrate all associated threads to point to the new path

Option 3: Project Settings UI

Add a new "Update Project Location" option in the project context menu or settings that allows users to manually specify the project's new path and re-establish thread connections.

Benefit

This would prevent users from losing valuable conversation history when they reorganize their projects, which is a natural part of development workflow.

Additional information

Related Issue

This feature request is related to issue #11019, where the Codex team confirmed that threads are associated with the absolute file path of a project. They suggested that "a way to update existing threads to point at a new location after you move your project" would be a good solution.

Use Case Example

  1. User has projects in ~/Desktop/Projects/
  2. User creates multiple conversation threads in Codex App for these projects
  3. User moves the folder to ~/Projects/ (using Finder, terminal, etc.)
  4. User opens Codex App to access those threads
  5. Current behavior: Threads show "This project folder was deleted or moved" and are inaccessible
  6. Desired behavior: Codex detects the issue and helps user recover the threads by updating the project path

This is especially important for users on the free tier who may not have other conversation history preserved.

View original on GitHub ↗

19 Comments

github-actions[bot] contributor · 5 months ago

Potential duplicates detected. Please review them and close your issue if it is a duplicate.

  • #11019

Powered by Codex Action

jmsharitt80 · 5 months ago

Just moved my project to a new directory as a result of a Codex recommendation to rename my volume. Would love to see a feature that allowed me to update the Codex thread to point to the new location.

Pabce · 5 months ago

Moving directories around is common during project development, especially during early stages or big refactors. I agree that an option to change the project directory on the Codex app preferences would be very useful.

ryanmish · 4 months ago

Very surprised there is no way to do this. would be trivial

hsw28 · 4 months ago

desperately need this feature as well

jaredar1232 · 4 months ago

Hitting this issue

noshi2x · 4 months ago

Same just encountered this issue. At the moment I just prompted the new path location, my process still works, but the message "Current working directory missing. This thread's working directory no longer exists" is still present.

w00kie · 4 months ago

Additionally, I found that using the "Hand Off" button to create a worktree for the thread will use a path like ~/.codex/worktrees/6138/yourproject without a chance to give a preferred path. Then if you use git worktree move to move it to a nicer path (if I'm going to work for days on a refactor, I want it somewhere nice and visible) codex will not follow the git command and there is no way to tell it to look for the files in the new path.

m-thomson · 3 months ago

What a pathetic joke. If you move your project, all history/context is detached? Really?

The ability to move project folders is a basic-level feature of every code (and non-code) tool on the planet of the past thirty years.

Adam-Bull · 3 months ago

Turns out this can be done pretty easily by an agent with a single prompt. Here is an agent skill I made to get me by until they add this feature to Codex:

https://github.com/Adam-Bull/Codex-thread-toolkit

lgallindo · 2 months ago

Any updates on this?

kylemaclaren · 2 months ago

@Adam-Bull your skill worked great! I submitted a small PR to also re-add the updated chats under the sidebar folders/projects. Without it, existing sidebar folders show as having "no chats" since the project still points to the wrong path. 🙌

PopSplash · 2 months ago

Has anyone tried manually pointing .codex/sessions files to the new folder path? The chat sessions should be portable along with the projects. When I installed Codex I set the default path to my Documents folder, and I wish to change to a more appropriate dev folder outside my windows user folder.

ialexryan · 2 months ago

@Adam-Bull's https://github.com/Adam-Bull/Codex-thread-toolkit worked great for me! I just asked ChatGPT in a new browser window how best to run it, so that I could keep Codex completely quit while I was mucking about with its internals. Or I suppose you could use Claude Code as the doctor 😁

tajemniktv · 2 months ago

I still can't believe it's not a feature. You technically can do it manually (or possibly with a script), but having to fallback to not-native solutions in this era is so off-putting...

ozcanoguz · 2 months ago

Thanks to @Adam-Bull s skill, I also have completed my migration to new folder as my project setup was totally broken due to iCloud sync that I had selected a wrong directory...

Blankdlh · 1 month ago

I ran into a similar local-project move problem and extracted my workaround into a small open-source CLI:

https://github.com/Blankdlh/codex-workspace-migrator

It is not an official Codex fix, but it may be useful as a temporary workaround for people who have already moved or renamed a local Codex project directory.

kevinb9n · 1 month ago

Fixing this would be especially nice if no one is going to fix #19913

pacolaf · 11 days ago

I ran into this on Windows and published a small open-source workaround:

https://github.com/pacolaf/codex-project-path-migrator

It performs a dry-run, validates the current Codex state structure, backs up
the complete .codex directory, migrates structured path references, and rolls
back on failure. It is Windows-only, uses the Python standard library, and is
intended as an unofficial temporary solution until native path remapping is
available.