Browse, search, and review local Codex CLI session history on Windows.
Codex Session Viewer is a Windows-first, local offline tool for exploring Codex CLI conversations. It scans %USERPROFILE%\.codex, reads sessions, archived_sessions, and history.jsonl, then turns raw JSONL event streams into a readable session browser.
- Auto-discover the local
.codexdirectory on Windows - Session list with keyword and date filtering
Reading ModeandRaw Mode- Reading-mode filters for
User,Assistant,Summary, andTool - In-session search
- Timeline navigation for long sessions
- One-click copy for summaries, clean dialogue, messages, commands, and outputs
- Fully local and offline; no session data is uploaded
- Windows
- Node.js 20+ (latest LTS recommended)
- A local
Codex CLIdata directory on the machine
Default Codex directory:
%USERPROFILE%\.codex
Common contents:
%USERPROFILE%\.codex\sessions
%USERPROFILE%\.codex\archived_sessions
%USERPROFILE%\.codex\history.jsonl
git clone https://github.com/li0on3/codex-session-viewer.git
cd codex-session-viewer
npm startOpen:
http://localhost:4173
If no .codex directory is detected, the app will show an empty state.
npm testindex.html static entry
styles.css page styles
src/app.js frontend rendering and interactions
src/lib/session-view.js session shaping, filtering, and timeline logic
src/server/server.js local HTTP server
src/server/codex-store.js Codex directory discovery and JSONL loading
tests/ Node built-in tests
docs/ product and design notes
- All data is read and rendered locally
- No remote upload is performed by default
- The app only reads from the local
.codexdirectory at startup
- Windows is the only first-class target for now
- This is currently a source-run project, not an installer package
- The current default flow relies on
%USERPROFILE%\.codex
This project is licensed under the MIT License.
这是一个只面向 Windows 的本地离线工具,用来浏览 Codex CLI 的历史会话。
它会自动扫描当前用户目录下的 %USERPROFILE%\.codex,读取 sessions、archived_sessions 和 history.jsonl,把原始 JSONL 事件流整理成更适合阅读的页面。
- 自动发现 Windows 上的
.codex目录 - 会话列表、关键词筛选、时间筛选
阅读模式与原始模式- 阅读模式支持
用户/Assistant/摘要/工具过滤 - 会话内搜索
- 长会话时间线导航
- 一键复制摘要、纯对话、消息、命令和输出
- 全程本地运行,不上传会话内容
- Windows
- Node.js 20+,推荐使用较新 LTS
- 本机已经使用过
Codex CLI,并且存在本地会话目录
默认会话目录:
%USERPROFILE%\.codex
常见内容包括:
%USERPROFILE%\.codex\sessions
%USERPROFILE%\.codex\archived_sessions
%USERPROFILE%\.codex\history.jsonl
git clone https://github.com/li0on3/codex-session-viewer.git
cd codex-session-viewer
npm start启动后打开:
http://localhost:4173
如果本机没有检测到 .codex 目录,页面会显示空状态。
npm testindex.html 静态入口
styles.css 页面样式
src/app.js 前端交互与页面渲染
src/lib/session-view.js 会话整理、过滤、时间线等纯逻辑
src/server/server.js 本地 HTTP 服务
src/server/codex-store.js Codex 会话目录发现与 JSONL 读取
tests/ Node 内置测试
docs/ 产品说明与设计文档
- 所有数据都在本地读取和展示
- 默认不会上传到任何远端服务
- 启动时只会读取本机
.codex目录
- 当前版本只优先支持 Windows
- 目前是源码运行版,不是安装包版
- 目前默认依赖
%USERPROFILE%\.codex
本项目采用 MIT License。