Box-drawing tables to Markdown
Terminal tools draw tables with Unicode box characters. Copy one and you get a picture of a table rather than a table: the columns are held apart by spaces and the borders are โโโฌโ. Paste that into a document, a pull request or an issue tracker and it falls apart.
This finds those tables, pulls the cell contents out - joining cells that were split across several lines - and rebuilds them as a real Markdown table.
Pasted from the terminal
โญโโโโโโโโโโโโโโโโฌโโโโโโโโฌโโโโโโโโโโฎ โ File โ Lines โ Status โ โโโโโโโโโโโโโโโโโผโโโโโโโโผโโโโโโโโโโค โ session.ts โ 64 โ updated โ โ middleware.ts โ 22 โ added โ โฐโโโโโโโโโโโโโโโโดโโโโโโโโดโโโโโโโโโโฏ
What you get back
| File | Lines | Status | | --- | --- | --- | | session.ts | 64 | updated | | middleware.ts | 22 | added |
Works with any terminal
The tool has no idea where your text came from, and does not need to. It reads what you paste and cleans it.
That covers an SSH session that wrapped everything at 80 columns, a tmux pane that broke lines at the divider, a tailed log full of colour codes, build output padded out to the terminal width, and any plain shell. None of those has a native cleanup of its own, and they all produce the same handful of problems.
What about Claude Code's built-in copy?
Claude Code now cleans terminal text automatically when you select it. That covers most of what this tool was originally built for. If it covers you, use it - it is one less step.
What it does not do: convert box-drawing tables to Markdown, clean up text you copy back out of the prompt input, or help you anywhere outside Claude Code. That is what is left, and it is why this page is still here.
What is this?
Every so often you need to copy a big lump of text out of the terminal. And when you do it's full of line breaks and god knows what else and, well โฆ it sucks.
This tool de-sucks it. And while it's at it, it deals with pretty much anything you might copy out of the terminal and strips out all of the junk - ANSI colour codes, trailing spaces, paragraphs broken mid-sentence, quote markers, box-drawing characters, progress bar frames - it gets rid of it all and gives you decent looking text again, how you would have expected it to be.
It should work with any terminal emulator - VS Code, Windows Terminal, iTerm2, PowerShell, tmux, Warp, Alacritty, and the rest. Free, instant, nothing leaves your browser, bla bla bla, etc.
Yes, you could get an LLM to roll you your own in approximately five minutes. But hey, I did test it all, and that took quite a bit longer than the first five minutes, and was significantly less fun. You're very welcome.
What does it fix?
An LLM wrote this bit. Not this bit (or this one) - the next bit. But it's just doing its best OK, and you have to appreciate the enthusiasm. Also, it is all 100% confirmed factually correct, I even read it once. OK, I skimmed it. It seemed fine ;)
ANSI Escape Codes
Terminals use colour codes for syntax highlighting, diff views and status indicators. When you copy, these invisible ANSI sequences come with it - your text looks clean in the terminal but pastes as garbled characters. This strips all SGR, cursor, OSC and bracket sequences.
Broken Paragraphs
Your terminal wraps long prose at 80 or 120 characters. When you copy, each wrapped line becomes a separate line break. Paste that into an email or a document and it looks terrible. This detects soft-wrapped prose and reflows it back into proper paragraphs.
Trailing Whitespace
Plenty of terminal programs pad every line with spaces to fill the terminal width. A 30-character line becomes 160 characters of mostly invisible spaces. This affects formatting when pasting into code editors, markdown files, or anywhere that preserves whitespace.
Quote Markers
Some tools mark quoted blocks with the โ character. These copy into your text as visible symbols that don't belong in the output. This strips them and reveals the original quoted content.
Tool Output & Diffs
Output from build tools, version control and coding agents contains line numbers, diff markers and TUI box-drawing characters. These are structured content that should stay exactly as they are - the paragraph reflow deliberately preserves them while fixing everything around them.
Progress Bar Overwrites
Long-running commands use carriage returns so progress bars and spinners overwrite the same line. Copy-paste captures every intermediate frame, turning a single progress bar into a wall of concatenated states. This simulates the overwrite to show only the final result.
Backspace Overprinting
Man pages and some legacy programs use backspace characters to render bold and underline text by overprinting. This resolves the overprint sequences back to clean readable text. Rarer than the rest, but it's in the pipeline.
Tab Characters
Tab characters copy inconsistently across terminals - sometimes as literal tabs, sometimes as varying numbers of spaces. This normalises them to consistent 4-space indentation so your pasted output lines up properly.
Box-Drawing Tables
Terminal tools render tables with Unicode box-drawing characters (โโโฌโ etc.). Copy-paste preserves the grid visually but it's unusable in documents, emails or issue trackers. This rebuilds them as clean Markdown tables - there's a worked example further up the page.
Shell Prompts
When copying a command session, prompts like user@host:~$, PS C:\>, or >>> come with it. Toggle this on to strip common shell prompt formats from line beginnings. Off by default because it's a destructive operation on non-prompt content.