Skip to content

Clean Pasted Text

Paste terminal-wrapped output. Get back clean, properly reflowed text.

Paste here

0 chars · 0 linesRuns locally — nothing leaves your browser

Cleaned output

1 chars · 2 lines

What this fixes

  • Hard line breaks from the terminal width: wrapped lines are joined back into the original paragraphs.
  • Left gutter / column padding: common prefixes like │ , ⎜ , >, leading spaces are stripped.
  • ANSI color codes: escape sequences from colorized output get removed.
  • Structure preservation: blank lines, bullet lists, numbered lists, headings, code fences, and tables are kept intact.

About the text cleaner

Text copied out of a terminal arrives broken. Lines are cut at whatever width the window happened to be, there is padding down the left side, and colour codes come along as unreadable escape sequences. Pasted into a document or a message, it looks like a mess.

This tool puts it back together: sentences are rejoined into flowing paragraphs, the gutter is stripped, and the escape codes are removed, while genuine structure such as lists and code blocks is kept.

How to use it

  1. Paste the text you copied from a terminal, a log, or an AI transcript.
  2. Look at the cleaned version beside it and check the paragraphs read the way you expect.
  3. Adjust the options if the source had unusual padding or you want line breaks preserved.
  4. Copy the result and paste it wherever it needs to go.

Good to know

  • •Rejoins lines that were wrapped by terminal width, without merging paragraphs that were meant to be separate.
  • •Removes ANSI colour codes and left-hand column padding.
  • •Leaves indented code and list structure intact, since those line breaks carry meaning.
  • •Runs entirely in the browser, so log output with internal detail in it stays on your machine.

Common questions

How does it know which line breaks to remove?

It looks at where lines end. A break in the middle of a sentence at a consistent column is wrapping and gets removed. A break after a full stop, before a list item, or inside an indented block is deliberate and is kept.

Will it damage code I paste in?

No. Indented blocks are treated as code and left alone, because reflowing them would destroy the meaning.

What are ANSI codes?

They are the invisible instructions a terminal uses to colour text. Copied into a plain editor they show up as sequences like [0;32m. The cleaner strips them out.

Can I use it on text from ChatGPT or Claude?

Yes. That is one of the main uses. Transcripts copied out of a chat interface often carry the same hard wrapping and stray padding as terminal output.