# Where Goose stores your session history

> Goose keeps sessions in a SQLite database, sessions.db, under ~/.local/share/goose. How to find it on each system, export sessions and import other agents' history.

Source: https://groundedby.com/agents/goose (updated 2026-10-29)

Goose, the open-source agent started at Block and now at aaif-goose/goose, stores sessions in SQLite.

## Where the database is

| System | Path |
| --- | --- |
| macOS, Linux | `~/.local/share/goose/sessions/sessions.db` |
| Windows | `%APPDATA%\Block\goose\data\sessions\sessions.db` |

`GOOSE_PATH_ROOT` changes the root. The `sessions` table holds tokens, cost, model and working directory; `messages` holds each message as JSON; `usage_ledger` tracks usage.

## Resume, export and import

```bash
goose session --resume
goose session --resume --fork
goose session list
goose session export --format markdown   # or json, yaml, html
goose session import <file.jsonl>        # Claude Code, Codex or Pi sessions
goose session remove
goose run --no-session "..."             # a run that saves nothing
```

## Privacy notes

Sessions are local only. The groundedby [evaluator](/evaluate) does not read Goose's database yet.

## Questions

**Where does Goose save sessions?**

In ~/.local/share/goose/sessions/sessions.db on macOS and Linux, and %APPDATA%\Block\goose\data\sessions\sessions.db on Windows. GOOSE_PATH_ROOT moves it. Versions before 1.10.0 used .jsonl files, imported into the database once.

**Can Goose import Claude Code or Codex sessions?**

Yes. goose session import accepts Claude Code, Codex and Pi .jsonl files.

## Sources

- [Goose docs, session management](https://goose-docs.ai/docs/guides/sessions/session-management)
- [Goose source, session manager](https://github.com/aaif-goose/goose/blob/v1.57.0/crates/goose/src/session/session_manager.rs)
