Skip to content

[BUG] Cost summary no longer displayed when exiting Claude Code session #9463

Description

@cybra-northco

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?

Cost summary no longer displayed when exiting Claude Code session

Description

The automatic cost summary that previously appeared when quitting/exiting a Claude Code session is no longer
being displayed.

Expected Behavior

When exiting a Claude Code session, a cost summary should be automatically displayed showing:

  • Total cost
  • Total duration (API)
  • Total duration (wall)
  • Total code changes
  • Usage by model

Current Behavior

When exiting a Claude Code session, no cost information is displayed automatically.

Workaround

The /cost command still works correctly during the session and displays all expected information:

Total cost:            $0.0411                                                                                
Total duration (API):  30.7s                                                                                  
Total duration (wall): 1m 4s                                                                                  
Total code changes:    0 lines added, 0 lines removed                                                         
Usage by model:                                                                                               
    claude-3-5-haiku:  10.5k input, 411 output, 0 cache read, 0 cache write ($0.0100)                         
       claude-sonnet:  13 input, 483 output, 40.0k cache read, 3.1k cache write ($0.0310)                     

Environment

  • Platform: Linux
  • OS Version: Linux 6.14.0-33-generic

Impact

This makes it harder to track session costs without manually running /cost before each exit.

What Should Happen?

Please restore the automatic cost summary display on session exit, or provide a configuration option to enable
it.

Error Messages/Logs

Steps to Reproduce

  1. Run claude from command line
  2. Run a couple of queries inside claude
  3. Quite claude with Ctrl-D

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

No response

Claude Code Version

2.0.14

Platform

Anthropic API

Operating System

Ubuntu/Debian Linux

Terminal/Shell

Other

Additional Information

No response

Activity

  1. github-actions commented on Oct 13, 2025

    @github-actions

    Found 1 possible duplicate issue:

    1. [FEATURE] Pre-Exit Hook ( or bring us back Automatic Cost Display on Exit) #9293

    This issue will be automatically closed as a duplicate in 3 days.

    • If your issue is a duplicate, please close it and 👍 the existing issue instead
    • To prevent auto-closure, add a comment or 👎 this comment

    🤖 Generated with Claude Code

  2. github-actions commented on Oct 16, 2025

    @github-actions

    This issue has been automatically closed as a duplicate of #9293.

    If this is incorrect, please re-open this issue or create a new one.

    🤖 Generated with Claude Code

  3. github-actions commented on Oct 23, 2025

    @github-actions

    This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.

  4. locked as resolved and limited conversation to collaborators on Oct 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    duplicateThis issue or pull request already exists

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions