Skip to content

[FEATURE] Incognito mode in Claude Code #9044

Description

@benjaminjackson

Preflight Checklist

  • I have searched existing requests and this feature hasn't been requested yet
  • This is a single feature request (not multiple features)

Problem Statement

When I run Claude code in --print mode, I usually don't need to refer to that conversation later.

For example, I often use it to automatically commit changes to my code.

These conversations aren't something I'll ever refer back to, BUT they end up cluttering up the conversation history when I try to find an earlier session using /resume.

Proposed Solution

I'd like to be able to run claude --print --incognito. This would prevent the conversation history from being stored in ~/.claude/projects.

Alternative Solutions

I can't think of any other way to accomplish this other than a native flag.

Priority

Medium - Would be very helpful

Feature Category

CLI commands and flags

Use Case Example

Example:

  1. I make some changes with Claude Code.
  2. I leave the session and run claude -p "/dev:commit" --incognito
  3. Claude Code commits the files
  4. I run claude -c
  5. Claude resumes the previous session where I made the changes
  6. The conversation history for the commit workflow is not stored

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions