CLI markdown tables are not rendered as readable aligned tables in TUI output

Resolved 💬 2 comments Opened Mar 22, 2026 by Microck Closed Mar 22, 2026

What version of Codex CLI is running?

codex-cli 0.115.0

What subscription do you have?

ChatGPT Plus / API-backed local usage

Which model were you using?

Model-independent; reproduced with markdown output from Codex CLI regardless of model

What platform is your computer?

Linux 6.8.0-1047-oracle aarch64 aarch64

What terminal emulator and version are you using (if applicable)?

tmux on Linux terminal environment (TERM=dumb in the current session)

What issue are you seeing?

Markdown tables in Codex CLI/TUI output are not rendered as readable terminal tables. They are effectively treated as plain markdown text, so column structure is lost and table-heavy responses are difficult to scan.

I investigated this in the renderer and confirmed the issue is in the CLI source, not something that can be fixed with a plugin or skill.

What steps can reproduce the bug?

  1. Run Codex CLI in the terminal.
  2. Ask for output that includes a markdown table, for example a small comparison table.
  3. Observe the rendered output in the TUI.

Minimal markdown sample:

| Left | Center | Right |
|:-----|:------:|------:|
| a    | b      | c     |

Current behavior is that this does not render as a proper aligned terminal table.

What is the expected behavior?

The CLI should parse markdown tables and render them as readable aligned plain-text terminal tables, including:

  • header separator rendering
  • column alignment
  • cell wrapping within available width
  • sensible handling of links inside table cells
  • consistent behavior in both codex-rs/tui and codex-rs/tui_app_server

Additional information

I already have a tested patch ready locally.

Implementation summary:

  • enable pulldown-cmark table parsing
  • render tables as aligned plain-text terminal tables
  • preserve indentation/prefix behavior around tables
  • keep codex-rs/tui and codex-rs/tui_app_server in sync
  • add focused tests and snapshot updates

Validation completed locally:

  • cargo test -p codex-tui --lib table_
  • cargo test -p codex-tui-app-server --lib table_
  • cargo test -p codex-tui --lib markdown_render_complex_snapshot
  • cargo test -p codex-tui-app-server --lib markdown_render_complex_snapshot
  • just fmt
  • just fix -p codex-tui
  • just fix -p codex-tui-app-server
  • ./tools/argument-comment-lint/run.sh

If this approach matches maintainers' intended direction, I can open the PR immediately.

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗