Codex Sessions Manager is a local running SPA interface that simplifies working with session archives created by the Codex coding agent.
By default, Codex allows you to resume a previous session only if you manually saved its session ID.
If the ID was lost, you have to browse through the .codex/sessions folder and inspect files one by one to find the right session.
This application solves that problem by providing a clean, convenient UI for browsing, searching, and managing Codex sessions directly in your browser.
- 📂 Browse all local Codex sessions
Automatically discovers and displays session files stored by Codex. - ⚡ Copy a ready-to-use command to resume any session
One click gives you the exact command to jump into the correct project directory and continue the session using its ID. - 📝 View the full conversation history within each session
No need to open or parse raw JSON files manually. - 🧹 Filter or delete empty and unwanted sessions
- 🗂 Group sessions by date or by project
- 📊 View detailed statistics, including:
- number of commands issued per session
- time spent inside a session
- project-level totals
- and more
The app runs entirely on your local machine and never sends any data anywhere.
This section covers deploying on a Windows machine that uses WSL2 for Codex, with Node running inside a Docker container and sessions stored in WSL.
- Windows 10/11 with WSL2 installed and a Linux distribution set up.
- Docker Desktop for Windows with WSL backend enabled.
- pnpm installed in the Docker container (or use
corepack enable). - Codex installed and runnable directly inside WSL.
- Codex writes sessions to
/home/<user>/.codex/sessions/inside WSL. - The app expects a
sessions/folder in its working directory. - You must mount the WSL sessions directory into the container at
/var/www/codex-sessions-manager/sessions.
- Copy
.env.exampleto.envif present (or create.env) and set:SESSIONS_ROOT_PATH=/home/<user>/.codex/sessionsVITE_HOST=0.0.0.0(default binding for dev/preview)VITE_PORT=5172(default port; change if needed to avoid conflicts)
- Never hardcode absolute Windows paths in code; use the env var above.
- Open the project in WSL:
cd /var/www/codex-sessions-manager - Build the image (once):
docker build -t codex-sessions-manager . - Run the container with volume mapping:
Replace<user>with your WSL username.docker run --rm -it \ -p 5172:5172 \ -v /home/<user>/.codex/sessions:/var/www/codex-sessions-manager/sessions \ codex-sessions-manager \ pnpm run dev -- --host "$VITE_HOST" --port "$VITE_PORT"
- The
-vflag makes live session files from Codex available to the app. - The
--hostflag binds to all interfaces so the browser can reach Vite. - Adjust
-p 5172:5172if you changeVITE_PORT.
- The
- Open the app:
In Windows, browse tohttp://localhost:5172.
- Run Codex directly in WSL (
codex ...) so it writes to/home/<user>/.codex/sessions/. - Click Refresh in the app header to pull new sessions without restarting the dev server.
If you need a production bundle inside the container:
docker run --rm -it \
-v /home/<user>/.codex/sessions:/var/www/codex-sessions-manager/sessions \
codex-sessions-manager \
pnpm run buildServe the dist/ directory with your preferred static server (e.g., pnpm run preview -- --host "$VITE_HOST" --port "$VITE_PORT").
- No sessions visible: Confirm the volume mount path and
SESSIONS_ROOT_PATHmatch/home/<user>/.codex/sessions. Ensure Codex has created session files. - Port conflicts: Change the
-pmapping and--portflag consistently. - Permissions issues: Verify your WSL user owns the session directory; use
chmod -Rorchowninside WSL if needed.