Repository navigation
Feature request: lossless, portable Codex project/session export-import for cross-device and Git workflows #47196
Description
What feature would you like to see?
Please add an official, supported Codex Project + Session export/import format that allows a project to be moved to another computer and reopened without losing its Codex working context.
The goal is not merely to sync source code or produce a summary such as AGENTS.md. I want a durable, portable representation of the actual Codex project and its sessions.
1. Lossless session/project restoration
After exporting a Codex project on machine A and importing/opening it on machine B, Codex should immediately be able to access the same durable session context, including as applicable:
- Full user/assistant conversation history
- Tool-call history and results
- Terminal command history and captured command output
- Debugging results, logs, stack traces, test output, experiment results, and other generated evidence
- Diffs/patches and Codex-produced changes
- Session metadata, titles, timestamps, task state, and relationships between sessions
- Project metadata and repository/worktree association
- Attachments or generated artifacts referenced by the session, where they are part of the durable Codex record
This should be a supported round-trip format, not a best-effort summary and not a dependency on undocumented internal SQLite/JSONL layouts.
The important acceptance criterion is:
Export on machine A -> copy/clone to machine B -> import/open -> Codex can continue with the same historical context without requiring the user to manually reconstruct prior discussions, debugging evidence, or experiment results.
I am referring to durable session/project state, not a byte-for-byte VM/RAM snapshot of a currently running debugger process.
2. Self-contained, portable project directory
Please support storing/exporting the Codex project state in one directory associated with the repository, for example:
MyProject/
├── .git/
├── src/
├── AGENTS.md
└── .codex-project/
├── manifest.json
├── sessions/
├── artifacts/
├── debug-results/
└── index/
The exact layout is not important, but it should have these properties:
- Self-contained and easy to archive, copy, back up, and move
- Uses a versioned, documented schema
- Uses relative/project-root-aware paths so a project can move from
C:\...toD:\...or to another OS where possible - Supports integrity/version checking during import
- Does not require copying the user's entire global
CODEX_HOME - Clearly separates portable project state from machine-specific state, credentials, secrets, caches, and transient processes
A simple workflow could be something like:
codex project export --output .codex-project/
codex project import .codex-project/
or, ideally, Codex Desktop could recognize the project metadata automatically when the repository is opened.
3. Git-friendly and collaboration-friendly
The portable Codex project directory should be designed to work well with Git so that a team can optionally version and share Codex context together with the source repository.
Important properties:
- Stable, documented, preferably text/JSON/JSONL-based formats where practical
- Deterministic or low-noise files so Git diffs remain useful
- Large/binary artifacts can be separated or optionally handled via Git LFS
- Clear
.gitignoreguidance for caches, temporary files, credentials, and machine-specific state - No secrets or local credentials included by default
- Multiple developers should be able to clone a repository and recover the shared Codex project/session history
- Provenance should be preserved so it is clear which session/user/machine produced a result
- Ideally support merging or at least safely coexisting session histories from multiple contributors without corrupting project state
This would make Codex projects behave more like a portable development workspace/solution rather than a collection of machine-local UI state.
Why this matters
For long-running engineering work, AGENTS.md, summaries, or manually maintained context files are useful but inherently lossy. They often preserve the current conclusion while losing:
- why earlier approaches were rejected,
- exact error messages and stack traces,
- commands and outputs,
- failed experiments,
- intermediate debugging evidence,
- and the chronology that led to an architectural decision.
That information can be critical months later.
A supported lossless project/session format would also solve several operational problems:
- moving between workstation and laptop,
- rebuilding or replacing a development machine,
- backing up Codex work,
- disaster recovery,
- team handoff,
- auditability/reproducibility,
- and keeping AI-assisted engineering context next to the source code.
Related existing requests
This request overlaps with, but is intentionally broader than:
- Feature request: option to export the entire session #13267 — export the entire session
- Feature request: Cross-device sync for Codex Projects and Chats #21803 — cross-device sync for Codex Projects and Chats
- Feature Request: Cloud Sync for Codex Projects Across Devices #32350 — cloud sync for Codex Projects across devices
- Feature request: Built-in session storage dashboard, backups, and safe bulk cleanup #38838 — session storage, backups, and export
Those requests address important parts of the problem. The additional requirement here is a documented, lossless, round-trippable, project-scoped format that can live in one directory and optionally be versioned with Git for cross-device use and team collaboration.
Thanks for considering this.
Activity
github-actions commentedon Sep 22, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
jsegeren commentedon Sep 22, 2026
This is exactly the continuity gap I built Codex Migrate/Vault to address on Macs. It transfers actual local Codex history and selected workspaces with verified backup/rollback, and Vault adds encrypted scheduled backups, search, recovery, and export.
Free MIT CLI/source: https://github.com/jsegeren/codex-migrate
Signed Mac app: https://migrate.segeren.com/
Important boundary: it is Mac-only today and does not provide the official, Git-friendly, collaborative cross-platform format you’re proposing. OpenAI should still build that. But if your immediate workflow is moving or protecting Codex work between Macs, I’d be glad to help you test it.
ken-yu-masters commentedon Sep 22, 2026
Thanks for the thoughtful reply and for sharing Codex Migrate/Vault. It sounds like a very useful solution for Mac users, especially the backup, rollback, and recovery capabilities.
My own workflow is primarily Windows-based, and the main use case I’m trying to solve is cross-platform portability between Windows, Linux, and potentially macOS. I’m also particularly interested in a project-scoped format that can travel with the repository and work cleanly with Git for backup and collaboration.
So your tool addresses a very similar continuity problem, but the cross-platform and Git-friendly project format is the part I’m especially hoping OpenAI will support officially.
Thanks again for adding this context — it’s helpful to see that others are running into the same underlying problem.
luk2009 commentedon Sep 30, 2026
Adding support for this feature request with a macOS/Windows use case.
I use Codex on a MacBook Air M1 and a Windows 11 mini PC, with different projects using local files on each computer. I would like to export a project from one Codex installation and import it into the other while preserving its conversations, project instructions, important decisions, metadata, and pending tasks.
Copying the project folder transfers the files but does not preserve the Codex chat history. A CONTINUAR.md or similar handoff summary helps, but it is not equivalent to restoring the original project and sessions.
Please provide an official desktop export/import workflow that adapts project paths between macOS and Windows, supports projects without Git, and lets users safely merge imported work with existing projects.
Codex already provides an import workflow for other AI applications. Having an equivalent way to move work between installations of Codex itself would make the product more consistent and much easier to use across computers.
tangiblewaves commentedon Oct 1, 2026
I absolutely support this suggestion. I've been using Codex over an extended period on several complex local projects, and the chat history has become a core part of my project documentation. It captures decisions, discarded alternatives, debugging sessions, and the reasoning behind code changes. Because local Codex chats are not synced across devices, losing a machine also means losing that history. A built-in backup or export option – ideally with scheduling and easy restore on a new machine – would keep the local-first model but dramatically reduce the risk for long-running projects. For many of us, these chats are now a key part of our technical documentation and decision history.
jsegeren commentedon Oct 2, 2026
@tangiblewaves That’s precisely why I built an independent Codex backup/recovery tool for Macs. Are you using macOS? If so, I’d be glad to help you evaluate the local backup and export workflow.
tangiblewaves commentedon Oct 2, 2026
@jsegeren : Thanks a lot for your offer; unfortunately I'm on Windows. But I have an idea where the Codex data lives (all the json, SQLite etc. stuff), so I will use a Powershell script as backup for now. But I'd be happy to learn about any details that might be not so obvious; maybe I will peek into your sources 😉
My ideal would be that we see the Codex chat in our account, same like the regular ChatGPT chats :-) and are "simply there" when we install Codex on a new machine Hope Open AI has an ear 😊