Option to disable diff background highlight
Resolved 💬 16 comments Opened Feb 25, 2026 by acgxv Closed Feb 28, 2026
💡 Likely answer: A maintainer (etraut-openai, contributor)
responded on this thread — see the highlighted reply below.
What variant of Codex are you using?
cli
What feature would you like to see?
After https://github.com/openai/codex/pull/12581
I can't read. I don't like the background highlight.
<img width="1512" height="258" alt="Image" src="https://github.com/user-attachments/assets/456e4273-2204-4307-a4e7-784183db6c6c" />
@fcoury
Additional information
_No response_
16 Comments
https://github.com/user-attachments/assets/7eb6ca09-ad64-4996-be08-284898bccf3b
Every theme is unreadable
Which terminal emulator are you using? Which platform?
Ghostty, I also tested in Zed. All my tokyo-night* terminal themes are not happy with this.
BTW, I use
TERM=dumbdue to https://github.com/openai/codex/issues/2020. Even if this is fixed I will not use it as I dislike the black input box.But anyway, I would like to suggest that an option to disable this feature be available.
I can confirm that I cannot read anything anymore.
<img width="506" height="97" alt="Image" src="https://github.com/user-attachments/assets/bc8b4e7d-ec62-4d76-985b-278248a90d88" />
The green is too green and the red is too red. Every time I open this terminal, my retinas file a formal complaint. 😅
I use mintty 3.8.1.
Fortunately, mintty can actually change colors (they call it a "theme"). I switched the theme from “mintty” to “html” and finally: the text becomes readable again.
Edit: now ordered lists and code blocks become unreadable 😆 but sadly the "html" theme is the only theme among the others that don't let my eyes bleed.
I think I need to switch back to 0.104.0 for the current time.
+1 from my side. My eyes, they burn. The current add/remove diff line backgrounds are too strong for all themes due to being hardcoded in
codex-rs/tui/src/diff_render.rs.Suggested implementation path/spec:
[tui]:diff_background = "auto" | "off" | "theme" | "custom"auto(preserve current behavior)auto: current hardcoded palette (no behavior change)off: no add/remove line background, keep only fg/gutter/sign stylingtheme: derive add/remove backgrounds from theme scopes if availablecustom: use explicit user-provided colors.tmThemescope mapping forthememode:markup.inserted, fallbackdiff.insertedmarkup.deleted, fallbackdiff.deletedautofor missing scope/backgroundcustommode config keys (optional, with fallback toauto):diff_add_bg,diff_del_bg#RRGGBB(and optionally named/indexed later)DiffBackgroundConfigintostyle_line_bg_for/add_line_bg/del_line_bg/themeso users can verifytheme/custom/offquickly.This would cover both camps: users who want backgrounds disabled and users who want subtle, theme-matched diff backgrounds instead of hardcoded bright red/green.
+1 colour blind here and makes it awful to use, please add an option to turn it off.
I implemented in https://github.com/ignatremizov/codex/pull/1 but cannot open a PR here
We are working on a fix for this. Meanwhile, can you try running
set TERM=xterm-256first and then running codex and report back.I wanted to post that this change bugs me too:
<img width="286" height="61" alt="Image" src="https://github.com/user-attachments/assets/0eaa4dbd-dfa3-468a-b266-7ce6af75b440" />
I chose a theme which is not as terrible as others, but it's still hard to read. I'd prefer the previous 0.104 version with no background.
I'm running KDE Konsole, with terminal settings:
@fcoury please look at https://github.com/ignatremizov/codex/pull/1 (it has screenshots)
Nope, nothing changed, at least in mintty, @fcoury.
just to follow up the coloured syntax text in 0.104.0 and earlier was perfect and no problem for me and perhaps other colour challenged folks, it's the coloured backgrounds that cause a prob and make the underlying text unreadable.
https://github.com/openai/codex/commit/3b5996f988c35ef282e04df7b7f311a83b562363 is intended to fix this, but there is still no user config override for the background tint from theme files or config.toml [tui] directly
Ditching the diff theme is a solid move. I'm not sure why we’re trying to bake a full-blown code editor feature in TUI.
Nice. https://github.com/openai/codex/pull/13037
Works good now in latest pre-release.