Text to Nice Columns

Align messy, delimited text into perfectly spaced, readable columns.

Text to Nice Columns

This tool turns messy delimited data into cleanly aligned columns: CSV rows, tab-separated lists or plain space-separated values.
Paste your text or upload a file, choose the separator & padding, and the result appears in the "Output" field.


Load an example

1. Column separator
Auto-detect picks the delimiter that appears most consistently across your lines and falls back to whitespace.
2. Column padding
spaces between columns
0–20 – how much breathing room each column gets. Every column is measured against its widest value before the padding is added.
3. Options
Removes stray spaces around each value before measuring
Aligns digits along their right edge so magnitudes line up
Inserts a dashed line under the first row, like in a README table
Ready to align your text into nice columns.

Overview:

Delimited text – data where a comma, pipe, space or other character separates each value – is everywhere: CSV exports, log files, spreadsheet copies, code lists and command output. It is compact and easy to store, but almost impossible to read, because the values do not line up and your eye has to hunt through punctuation to follow a row.

Our "Text to Nice Columns" tool fixes that: it splits every line at the separator you choose (or lets the tool detect the most likely one), measures the widest value in each column, and re-prints the rows with enough padding between columns for all values to line up along straight vertical edges. Paste a blocked of comma-separated plant data and you get a table you can read at a glance; align an application's variable declarations and the values line up for easy comparison. This tool was used to prepare every before/after example you see below, and it is handy any time you need readable plain-text output in a monospace context: code editors, README files, terminal sessions, log viewers and diff tools.


What this Tool Does?

It works in four passes. First it splits your text line by line, keeping blank lines where they are. Second, it slices each line into cells at the chosen separator – automatically detected if you want – and optionally trims stray spaces around each cell. Third, it measures every column and finds its widest value. Fourth, it re-emits each row with every cell padded to its column's width plus your chosen padding, so the columns start (or end, for numbers) exactly where the previous column's longest value left off.

Nothing is re-ordered or removed: the tool keeps every line, every blank line and every cell in the same order it found them – it only inserts padding characters between the columns. You can paste text, upload a .txt or .rtf file, right-align numbers for magnitude comparison, add a dashed header line, and copy or download the result.


What This Tool Is Perfect For:

Previewing CSV data: See a comma-separated export as a real, lined-up table without opening Excel or writing an import step – a quick sanity check that the rows and columns survived the export.

Tidying log entries: Align timestamps, log levels, component names and messages of a pipe- or space-separated log so patterns and anomalies stand out at a glance.

Cleaning up code listings: Line up variable declarations, constants or column assignments in code comments and documentation so the values start on one edge.

Formatting CLI output: Turn raw command-line output into a readable table for README files, wiki pages and bug reports, complete with a dashed header line if you enable it.

Proofreading reports by eye: Compare rows of a small price list, schedule or roster side-by-side on paper, where a spreadsheet is overkill but neat columns still pay off.


Features:

Auto-Detect Separator: With the default "Auto-detect" option, the tool tests comma, pipe and semicolon across your lines and picks the delimiter that appears most consistently with at least two columns per line; if no delimiter qualifies, it falls back to splitting on whitespace (spaces and tabs together). For example, pasting this pipe-delimited log works without touching any setting:

Mon|Bought potting soil|12.40
Tue|Potted the basil|0
Sat|Repotted the fern|4.10

the output becomes:

Mon    Bought potting soil    12.40
Tue    Potted the basil      0
Sat    Repotted the fern     4.10

Manual Separator Choice (including Custom): Prefer to decide yourself? Choose Space / Tabs, Comma, Pipe, or Semicolon from the dropdown, or pick "Custom..." and enter any single character or string – useful for odd formats such as " - " separators in exported notes.

Adjustable Column Padding (0–20): The padding controls how much whitespace separates every column, so you can pack data in tightly (0–1 spaces for narrow screens) or spread it out (8–12 spaces for printed checklists). Every column is measured independently, so a short column never forces the others apart more than necessary.

Right-Align Numbers: With the switch enabled, cells made only of digits, decimals, negative signs or percent signs are aligned along their right edge instead of the left. This puts ones under tens under hundreds, making magnitudes instantly comparable. For example, this input:

Item,Amount
Notebook,3.75
Pens,12
Backpack,1

becomes a price table where the totals column reads itself:

Item        Amount
--------    ------
Notebook      3.75
Pens            12
Backpack         1

Header Separator: Enable "Add header separator" and a row of dashes is drawn under the first line, exactly as wide as its column and the gap before the next one. This turns a one-line header plus data rows into a self-contained plain-text table for READMEs, changelogs and issue reports.

Trim Cells and Skip Blank Lines: "Trim cells" cleans the accidental spaces people leave around values after a separator ("yes , no" becomes "yes", "no"), and blank lines in the input are kept as blank lines in the output, so multi-block documents keep their paragraph spacing.

Upload, Copy, Download and Live Mode: Instead of pasting, upload a .txt or .rtf file (larger files are truncated at 50,000 characters). Copy the aligned result to the clipboard or download it as nice-columns.txt. With the "Live mode" switch enabled (the default), the Output updates automatically as you type, paste or change a setting, so the alignment is always up to date.


How to Use this Tool?

Paste or Upload Your Data: Type or paste your lines into the "Input" textarea, or upload a .txt or .rtf file. Click the "Load an example" link above the textareas to load a sample reading list you can experiment with.

Choose the Separator: Leave "Auto-detect" on to let the tool find the delimiter itself, or pick Space / Tabs, Comma, Pipe, Semicolon, or a Custom character that matches your data.

Set the Padding and Options: Choose how many spaces (0–20) should sit between columns. Switch on "Right-align numbers" for numeric columns, and "Add header separator" if your first line is a title row that deserves a dashed line under it.

Apply: With Live mode switched on (the default), the aligned output appears in the Output field automatically as you type or change a setting. You can also press the "Apply" button at any time; your Input stays intact either way.

Copy or Download: Use the "Copy" link under the output to copy the aligned text to the clipboard, or the "Download" link to save it as a file.

Clear The Text Area: Press the "Clear" button to empty both textareas and reset every setting to its default.

Ready to untangle that wall of commas and pipes? Our online Text to Nice Columns tool is your best solution!


Examples

Every example below loads its own text and settings - click "Try it" and the tool does the rest.

1. Read a plant-care CSV at a glance

Auto-detect finds the commas and aligns a watering schedule so each column (name, interval, feeding) starts along one straight edge.

Input
Plant,Water every,Fertilizer
Basil,2 days,Every 2 weeks
Aloe,21 days,Never
Fern,3 days,Monthly
Output
Plant    Water every    Fertilizer
Basil    2 days         Every 2 weeks
Aloe     21 days        Never
Fern     3 days         Monthly

2. Tidy a pipe-delimited log file

Log lines with a date, level, component and message become a readable incident table – the pipe separator is detected automatically.

Input
2026-03-14|info|login|j.moreno
2026-03-14|warning|disk|92 percent
2026-03-15|error|backup|timeout after 30s
Output
2026-03-14    info       login     j.moreno
2026-03-14    warning    disk      92 percent
2026-03-15    error      backup    timeout after 30s

3. Align code variable declarations

Whitespace splitting lines up let keywords, names and values of a block of assignments for a clean, scannable code comment.

Input
let name = Javier
let retries = 5
let timeoutMs = 3000
let verbose = false
Output
let    name         =    Javier
let    retries      =    5
let    timeoutMs    =    3000
let    verbose      =    false

4. Turn a price list into a mini table

Right-aligned numbers put the decimal points in a column, and the dashed header line makes the first row read as a header.

Input
Item,Amount
Notebook,3.75
Pens,12
Backpack,1
Output
Item        Amount
--------    ------
Notebook      3.75
Pens            12
Backpack         1

FAQs

FAQ 1: Why does my aligned text look uneven after I paste it?
Answer: The alignment counts characters, not pixel widths, so the result only looks perfectly straight in a monospace font – the font used in this tool's output, in code editors and in plain-text files. In a proportional font (like the one in your email client) a "W" is wider than an "i", so equal character counts can appear unequal.

FAQ 2: What exactly does Auto-detect do?
Answer: It tests comma, pipe and semicolon across your non-empty lines and picks the separator that appears in the most lines while producing at least two cells per line. When no delimiter qualifies, the tool splits on runs of spaces and tabs together, which handles plain word lists and code snippets.

FAQ 3: What happens to rows with fewer values than other rows?
Answer: Nothing is lost. A short row is padded with empty cells so it reaches the column count of the widest row, and the missing cells simply render as blank space. Every line – including short ones and blank ones – keeps its original position in the output.

FAQ 4: Can I get my data back out as CSV after aligning it?
Answer: This tool is a one-way viewer: it turns separators into spaces for reading, and the padding replaces the original delimiter. To rearrange, rename or re-join delimited data rather than just viewing it, use our Swap Columns or Concatenate Text tools instead.

FAQ 5: What does the padding number change?
Answer: It is the number of spaces inserted between adjacent columns (0–20, default 4). It does not affect the values themselves: each column is first grown to fit its longest value, and the padding is added on top of that.

FAQ 6: Which cells count as numbers for right alignment?
Answer: Cells made of digits, optionally one comma or dot as a decimal mark, an optional leading minus sign, and an optional trailing percent sign – for example 12, -8.5 or 3,75%. Words and mixed text like 12a stay left-aligned.

FAQ 7: Do you save the text I insert in the tool?
Answer: No, we do not save your text. All processing happens in your browser and your data remains confidential. The textarea accepts up to 50,000 characters, and uploaded files larger than that are truncated.

FAQ 8: What is Live mode, and what do the "Try it" example buttons do?
Answer: Live mode is on by default: the Output updates automatically as you type or change a setting, without pressing "Apply". The "Try it" buttons in the Examples section load a ready-made scenario – input text, separator, padding and options – in one click; with Live mode on the result appears immediately, otherwise press "Apply".


Tools Worth Trying

TextToolz

The Ultimate Text Tools

TextToolz works seamlessly to let you convert and design your text. It is fast, reliable and secure. Trusted by thousands of users.