Skip to content

[BUG] CLI crazy scrolling #34242

Closed as duplicate
Closed as duplicate

Description

@nedlern

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?

❯ do you know you have a terrible bug. You routinely scroll the Claude CLI window back to
the top, making it impossible for me to read stuff above or copy it. And shame on you for not having a claude UI on top of bug reporting.

What Should Happen?

Claude CLI should scroll only when it's 'at the bottom', not when the user has 'taken control' of the scroll bar.

Error Messages/Logs

Steps to Reproduce

use claude CLI with big copy and pastes

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

No response

Claude Code Version

2.1.75 (Claude Code)

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

VS Code integrated terminal

Additional Information

No response

Activity

  1. VoxCore84 commented on Mar 14, 2026

    @VoxCore84

    We hit this too and collected working workarounds into a repo: claude-code-scroll-fix

    Quick fix (Windows Terminal): Add "snapOnOutput": false to your profiles.defaults in settings.json. Reduces jumping ~60-70%.

    Complete fix: Run Claude inside tmux — it completely decouples your scroll position from Claude's cursor repositioning. The repo has a one-click installer that sets up WSL + tmux + a Windows Terminal profile.

    Root cause: Claude Code uses CSI escape sequences to rewrite the thinking spinner in-place, and terminals follow the cursor position back up. snapOnOutput only fixes output-triggered scrolling, not cursor repositioning — tmux fixes both.

  2. duerra commented on Mar 15, 2026

    @duerra

    Complete fix: Run Claude inside tmux — it completely decouples your scroll position from Claude's cursor repositioning. The repo has a one-click installer that sets up WSL + tmux + a Windows Terminal profile.

    Unfortunately running in tmux is not working for me.

  3. nopa12 commented on Mar 17, 2026

    @nopa12

    reproduced on Ubuntu 22.04.5 with Claude Code 2.1.77

  4. riyandhiman14 commented on Mar 17, 2026

    @riyandhiman14

    Any update on this?? Getting this for the last few days on Mac M4 26.2, with Claude 2.1.77. I am using it in Iterm

  5. cruzlauroiii commented on Mar 18, 2026

    @cruzlauroiii

    A fix for this is available as a Claude Code plugin: #35683

    The scroll-fix plugin clamps cursor-up sequences within synchronized output blocks to the viewport height, preventing the terminal from scrolling to the top. Also includes Ctrl+6 freeze toggle for manual scroll control. Works on all platforms and terminals.

  6. cruzlauroiii commented on Mar 18, 2026

    @cruzlauroiii

    A fix is available as a Claude Code plugin: scroll-fix

    Install:

    /plugin marketplace add cruzlauroiii/claude-code
    /plugin install scroll-fix@cruzlauroiii-plugins
    

    Root cause: both Ink renderer AND readline/prompt system emit cursor-up sequences exceeding viewport height. The plugin clamps all cursor-up per write call. Also includes Ctrl+6 freeze toggle.

    PR: #35683

  7. yosmanyga commented on Mar 18, 2026

    @yosmanyga

    A fix is available as a Claude Code plugin: scroll-fix

    Install:

    /plugin marketplace add cruzlauroiii/claude-code
    /plugin install scroll-fix@cruzlauroiii-plugins
    

    Root cause: both Ink renderer AND readline/prompt system emit cursor-up sequences exceeding viewport height. The plugin clamps all cursor-up per write call. Also includes Ctrl+6 freeze toggle.

    PR: #35683

    Your solution injects minified code 🤔

  8. m-atisa commented on Mar 18, 2026

    @m-atisa

    Currently facing this issue on MacOS Tahoe 26.3.1 with Claude 2.1.78, I'm hoping this bug gets more traction.

  9. acsezen commented on Mar 18, 2026

    @acsezen

    I have the exact problem and it affects my workflow. I hope it gets fixed very very soon!

  10. nullbio commented on Mar 19, 2026

    @nullbio

    @ashwin-ant Please fix this urgently. It's so annoying.

  11. nullbio commented on Mar 21, 2026

    @nullbio
  12. felipekj commented on Mar 21, 2026

    @felipekj

    +1 — experiencing this on GNOME Terminal (same behavior as IntelliJ terminal). Cursor randomly scrolls up during streaming output.

  13. JinxCappa commented on Mar 23, 2026

    @JinxCappa

    this really is a terrible bug. it interrupts workflow so much, my pinky is tired of flexing to the page down key. this is a breaking bug. if you wish to prevent users from using other agents (opencode) then please stay critically alert to your own product. sorry for the tone but this is super frustrating and i've been forced to try and use the desktop app, as this bug hits me every single session in the cli.

  14. aaronmarkham commented on Mar 24, 2026

    @aaronmarkham

    This also happens in the integrated terminal in VS Code and there's no "terminal.integrated.scrollOnOutput": false option valid in the user configs there to use, so not sure what the quick fix is for that.

  15. sstraus commented on Mar 24, 2026

    @sstraus

    👍 We're experiencing the same issue embedding xterm.js 6.0.0 in a Tauri app. The scroll position jumps when Claude Code redraws its TUI while the user is scrolled up. Confirmed root cause: cursor-up sequences exceeding viewport height + ESC[2J/ESC[3J.

  16. parsakhaz commented on Apr 10, 2026

    @parsakhaz

    this is a huge issue. love claude code but this makes it really really hard to use

    hey. it's fixed at the terminal level here

    greenfield-inc/Pane#120

    open source, using xtermjs which is the same terminal as VS Code. feel free to copy this fix or download the latest release to run claude code on any operating system with the fix in place. i was so mad and frustrated at this that I had to fix it myself.

    Not just a scrolling issue — also a rendering/layout problem in VS Code's side-by-side panel mode.

    When Claude Code runs in VS Code with the terminal on one side and the editor on the other, text formatting breaks in unpredictable ways. Options and multi-line output get weirdly split left-right, text wraps incorrectly, and the whole experience feels janky rather than fluid. Combined with the scroll-jumping, longer sessions in VS Code become genuinely hard to follow.

    This isn't just macOS standalone terminal — it's very much a VS Code integrated terminal issue too.

    yeah i had to switch off cursor/vscode and build myself an ide that managed xtermjs (the library they both use) well enough for the complex TUIs to not break.

    works great and i have a fix for the scroll jump i just implemented rn here

    greenfield-inc/Pane#120

  17. claude commented on Apr 20, 2026

    @claude
    Contributor

    This is a duplicate of #35403, which was fixed as of version 2.1.101.

  18. github-actions commented on Apr 30, 2026

    @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.

  19. locked as resolved and limited conversation to collaborators on Apr 30, 2026
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

    area:tuibugSomething isn't workingduplicateThis issue or pull request already existsplatform:macosIssue specifically occurs on macOSplatform:vscodeIssue specifically occurs in VS Code

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions