Beware, Claude Code deletes >30 day old transcripts. Anthropic won't fix it

ojura2 pts0 comments

[BUG] Claude Code silently deletes conversation transcripts after 30 days by default · Issue #62476 · anthropics/claude-code · GitHub

//voltron/issues_fragments/issue_layout" data-turbo-transient="true" />

Skip to content

Search or jump to...

Search code, repositories, users, issues, pull requests...

-->

Search

Clear

Search syntax tips

Provide feedback

--><br>We read every piece of feedback, and take your input very seriously.

Include my email address so I can be contacted

Cancel

Submit feedback

Saved searches

Use saved searches to filter your results more quickly

-->

Name

Query

To see all available qualifiers, see our documentation.

Cancel

Create saved search

Sign in

//voltron/issues_fragments/issue_layout;ref_cta:Sign up;ref_loc:header logged out"}"<br>Sign up

Appearance settings

Resetting focus

You signed in with another tab or window. Reload to refresh your session.<br>You signed out in another tab or window. Reload to refresh your session.<br>You switched accounts on another tab or window. Reload to refresh your session.

Dismiss alert

{{ message }}

Uh oh!

There was an error while loading. Please reload this page.

anthropics

claude-code

Public

Notifications<br>You must be signed in to change notification settings

Fork<br>21.8k

Star<br>135k

[BUG] Claude Code silently deletes conversation transcripts after 30 days by default #62476

New issue<br>Copy link

New issue<br>Copy link

Open

Open<br>[BUG] Claude Code silently deletes conversation transcripts after 30 days by default#62476

Copy link

Labels<br>bugSomething isn't workingSomething isn't working

Description

joelhochstetter<br>opened on May 26, 2026

Issue body actions

Preflight Checklist

I have searched existing issues and this hasn't been reported yet

This is a single bug report (please file separate reports for different bugs)

I am using the latest version of Claude Code

What's Wrong?

cleanupPeriodDays defaults to 30, causing Claude Code to silently delete

~/.claude/projects//.jsonl files older than 30 days on

startup. There is no first-run disclosure, no warning before deletion, and the

setting is not surfaced in /config. I lost months of conversation history

before realizing this was happening.

Repro: Use Claude Code for >30 days without setting cleanupPeriodDays. Old

transcripts disappear.

Evidence on my machine: ~/.claude/history.jsonl shows 14 sessions / 1,315

prompts for one project from March–April. Only the current session's .jsonl

survives in ~/.claude/projects/. The cutoff matches the 30-day default

exactly. My settings.json does not override the default.

Impact: The code and git history remain, but the reasoning trail — design

discussions, debugging context, analysis — is gone. For research work that

context is the artifact.

What Should Happen?

Requested:

Change the default to non-destructive (disabled, or very long retention).

Disclose at first run; require opt-in for auto-deletion.

Soft-delete to a trash folder instead of unlink().

Surface the setting in /config.

Workaround for others: add "cleanupPeriodDays": 3650 to

~/.claude/settings.json immediately.

Error Messages/Logs

Steps to Reproduce

Use Claude Code for >30 days without setting cleanupPeriodDays. Old transcripts disappear.

Claude Model

None

Is this a regression?

I don't know

Last Working Version

No response

Claude Code Version

2.1.150

Platform

Anthropic API

Operating System

Ubuntu/Debian Linux

Terminal/Shell

Other

Additional Information

No response

Reactions are currently unavailable

Metadata<br>Metadata<br>Assignees

No one assigned

Labels

bugSomething isn't workingSomething isn't working

Type

No type

Fields<br>Give feedback

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

You can’t perform that action at this time.

claude code transcripts days default issue

Related Articles