Text Column Aligner
Align text into neatly formatted columns with customizable delimiters, per-column alignment, and live preview.
About This Tool
The Text Column Aligner is a free browser-based tool that transforms uneven, ragged text into perfectly aligned columns. Whether you are cleaning up CSV exports, formatting Markdown tables, tidying configuration files, or aligning variable declarations in source code, this tool does it instantly with a live preview as you type.
The tool works by splitting each line of your input on a configurable delimiter — tab, one or more spaces, comma, pipe, equals sign, colon, or a custom string of your choice. It then measures the maximum width of every column across all rows and pads each cell so that every column lines up perfectly. You can choose a separate output delimiter (for example, split on commas but output with pipes), set the alignment for each column independently to left, center, or right, and pick a custom padding character if needed.
Uneven rows are handled gracefully. If one row has fewer columns than the rest, the missing cells are filled with padding so the remaining columns still align. Trailing whitespace is trimmed automatically from each line to keep the output clean. The tool also offers five built-in presets — CSV Alignment, Markdown Table, Whitespace Alignment, Equals Sign Alignment, and Configuration File — that pre-fill the input and options so you can get started with a single click.
This column aligner complements other text tools in DevToolbox. For basic word and character statistics, try the Word & Character Counter. To compare two versions of aligned text, use the Diff Viewer. If you need to generate a Markdown table from scratch rather than re-aligning an existing one, the Markdown Table Generator provides a visual editor with row and column controls.
All processing happens entirely in your browser using JavaScript. No data is ever sent to a server, making it safe to align configuration files that contain database credentials, API keys, or any other sensitive information. The tool supports inputs of any reasonable size and updates the output in real time as you type or change options.
How to Use
- Paste or type your text into the Input panel on the left.
- Select the Input Delimiter that matches how your columns are separated (tab, comma, pipe, etc.). Use Custom for an arbitrary delimiter.
- Choose an Output Delimiter to control how aligned columns are separated in the result. Select Same as Input to keep the original delimiter.
- Adjust the Column Alignment for each detected column using the left, center, and right buttons. Use All Left, All Center, or All Right to set every column at once.
- Optionally change the Padding Character from the default space to another character (e.g., a dot or dash).
- Toggle Trim whitespace to strip leading and trailing spaces from each cell before aligning.
- Click Copy or press Ctrl+Shift+C to copy the aligned result to your clipboard. Use a Preset button to quickly load a sample configuration.
Popular Column Alignment Examples
FAQ
What delimiters are supported?
The tool supports tab, single space, multiple spaces (2+, 3+, 4+, 8+), comma, pipe (|), equals sign (=), colon (:), and any custom delimiter string you specify. Choose the one that matches how your input columns are currently separated.
Can I use a different delimiter for the output?
Yes. The Output Delimiter option lets you choose a different separator for the aligned result. For example, you can split on commas but output with pipes, or vice versa. You can also specify a custom output delimiter string.
How are uneven rows handled?
If some rows have fewer columns than others, the tool automatically pads the missing columns with the padding character so that all remaining columns still align properly. No data is lost or shifted.
Can I align each column differently?
Yes. Once the tool detects the number of columns in your input, per-column alignment controls appear. You can set each column to left, center, or right alignment independently. Shortcut buttons let you set all columns to the same alignment at once.
Is there a size limit for the input?
There is no hard limit, but the tool runs in your browser so very large inputs (tens of thousands of lines) may slow down the live preview. For typical use cases like configuration files, CSV exports, or code snippets, performance is instantaneous.
Is my data safe?
Yes. All processing runs entirely in your browser using JavaScript. No data is sent to any server. You can verify this by checking the Network tab in your browser's developer tools while using the tool.
What are the presets?
Presets are pre-configured examples that load sample text and set the appropriate delimiter and output options. They include CSV Alignment, Markdown Table, Whitespace Alignment, Equals Sign Alignment, and Configuration File. Click any preset to instantly see how the tool works.
Related Tools
Word & Character Counter
Count words, characters, sentences, paragraphs, and estimate reading time with keyword frequency analysis.
Markdown Table Generator
Build Markdown tables visually with an interactive editor. Add rows, columns, set alignment, and copy the output.
Diff Viewer
Compare two texts side by side with line-by-line and character-level diff highlighting.
Text Case Converter
Convert text between camelCase, PascalCase, snake_case, kebab-case, and other naming conventions.
CSV ↔ JSON Converter
Convert between CSV and JSON formats with delimiter selection, header toggle, and file drag-and-drop.
Fixed Width ↔ CSV Converter
Convert between fixed-width positional text and CSV format with column definitions, auto-detection, and presets.
TSV ↔ CSV Converter
Convert between tab-separated values and comma-separated values with proper quoting, escaping, and multiline support.