---
title: "Resume Codex session from latest jsonl file"
description: "Resume Codex session from latest JSONL file"
canonical: "https://ian.is/codex-session-resume"
language: "en"
---

[Ian Nuttall](https://ian.is/)

# Resume Codex session from latest jsonl file

September 3, 2025

Codex CLI pro tip:

restore the context from your most recent session by adding this function in your bash/zsh/fish config (ask codex to do it for you!)

run codex\_continue to use it

props to [@fcoury](https://x.com/fcoury) for sharing

![Image from the original X post](https://ian.is/media/tweets/1963304481593958748/1963304481593958748/fce7930bcebf4eb67d85b19018308b481f435b8d5c5a7d2aabf77973d75e5a60.jpg)

gist: [https://gist.github.com/iannuttall/d6eab4afee03832497c2147b9c135a21](https://gist.github.com/iannuttall/d6eab4afee03832497c2147b9c135a21)

## Newsletter

Join 9.2k subscribers
