Terminal Flickering
https://github.com/user-attachments/assets/00d2711a-1113-433c-a542-652ad3f5ce06
Thanks for the report. What terminal is that?
I've been having the same issue for weeks. It's the Windows terminal (win11 for me, WSL2 Ubuntu).
I've noticed it tends to happen when the terminal history gets quite long, so I'm not sure if that's related or not? Restarting Claude doesn't fix it, I have to either open a new terminal or clear the terminal first and then re-open.
Here's what I have for settings:
HISTCONTROL=ignoreboth
HISTSIZE=10000
HISTFILESIZE=10000
Does running /clear in claude resolve it?
Use !clear periodically to clear the bash history, this would stop the flickering from happening. This would not clear the context (unlike /clear)
It's WSL2 on Windows
Its happening when the whole thread gets long.
- In Windows - Open Windows Terminal
- Press Ctrl + , to open graphical settings.
- At the bottom left, click “Open JSON file” (or the {} icon).
- In the opened settings.json, locate the "profiles" section and add: "compatibility.enableUnfocusedAcrylic": false
e.g. "profiles": { "defaults": { "compatibility.enableUnfocusedAcrylic": false },
- Save the file and close it
- Close all open Terminal windows completely
- Reopen Windows Terminal. The flickering should now be gone when using WSL or other profiles.
Same for me, made a comment in a previous issue and added a video, see https://github.com/anthropics/claude-code/issues/392#issuecomment-2970234466
It happens to me on all terminals. I'm on iTerm2 Mac mostly
I feel like the issue is getting worse all of a sudden, especially navigation around the prompt input field. They seem somewhat related, because they seem to happen around the same times (i.e. when I notice navigation issues, I also notice flickering issues around the same time). All seem to be tied to the size of outputs, inputs, or overall session.
happens in ubuntu 24.04 terminal also.... this happens when the information overflows the current terminal viewport..... specially when using multiple parallel agents, this will happen... maybe on a bigger 4k monitor it doesn't but on 1080p it sure does.... just a guess
I am also facing this same problem in mac warp terminal. solve this asap!
I think we need a command to clear the chat history without it deleting the context.
I think we need a command to clear the chat history without it deleting the context.
I think this is almost there with /compact. The command just needs a slight extension.
Same issue for me. This is making claude code almost unusable. I am using wsl2 with arch linux.
Hi, maybe issue is related to term height? see https://github.com/vadimdemedes/ink/issues/359 and can you check possible fix in https://github.com/oclif/multi-stage-output/pull/11/files
xterm, flickering is annoying
Terminal Flickering is giving me headaches, please resolves it, I can not use it after certain time.
Warning: This might give people siezure who are susceptible to it also.
https://www.epilepsy.com/what-is-epilepsy/seizure-triggers/photosensitivity
I resolved this by clicking escape, and then message shows up in command field, and then i just press enter
This is also occurring for me in a variety of terminals across operating systems, as @SahilDahiya mentioned, this is an issue for those who have epilepsy. While not a personal issue for me, it is something to consider
I'd actually just like to add now that it affects my ability to type, as when it flickers, it seems to not register typing
Yes, super bad for me, I'm gonna have a seizure or something. Anthropic, unleash Claude Code to fix it itself. Terminal window and text and the whole thing flashing up and down out of control when typing and context/history is large. On MacOS, zsh, running in Cursor/VScode native terminal.
Lets see if they have their own github action running,
@claude jump in, read all of these comments, and fix this bug/bugs, these users are very important to us and we need to get the terminal experience 100% for them asap
@GustyCube I thought claude code was closed source - how are you going to fix this yourself...?
From what I can tell, moving to incremental rendering in Ink (the cli rendering lib claude code uses) might help (assuming improve ink, and then somebody who works on CC upgrades the version of Ink that CC uses). There is a work in progress over here for those that want to dig in -> https://github.com/vadimdemedes/ink/pull/708
@ashwin-ant Are you guys aware of this bug? My experience is that as soon as the terminal starts flickering its just a matter of time till it crashs, especially in VSCode and similar IDEs
In case someone is looking for a workaround, for some reason enabling "Maximize throughput at the cost of higher latency" option in iTerm2 (latest beta, not sure if that matters) stopped flickering on it's tracks, as soon as I clicked the checkbox. Have not seen any flickering all day today.
I see this flickering really bad when Claude Code has multiple sub-agents running at once. It's as though each sub-agent is trying to make TUI updates at once and the TUI goes crazy with flickering. Once the multiple agents have finished and I am back to a single agent (or they've all finished), the flickering completely stops.
When I continue the session with a new prompt that spawns multiple agents, the flickering comes back immediately.
I have also seen this happen with a lot of subagents and a long thread. CMD+K cleared the output temporarily but then the flickering started happening again. Eventually, that lead to a memory crash related to a GC issue.
Yeah, this is super bad, and happens across different terminals for me in different environments and different window sizes. I've actually switched to using new Codex VSCode extension now as this is unusable to me. Its good! Anthropic pretty please fix pretty please.
it's crazy that this has been an issue for 2 months or so and still hasn't been fixed 😂
How to solve it on cursor (WSL2, windows)
Yeah, I'm having the same issue running subagents and having an insanely flickering screen. If anyone finds a workaround, let me know!