Text Alignment & Padding
Align text left, center, or right with custom padding. Pad each line to a target width with fill characters.
About the Text Alignment & Padding
Our free online text alignment and padding tool lets you format lines to a uniform width. Choose left, center, or right alignment, set a target line width, and optionally customize the padding character (space, dot, dash, or custom). Each line is padded to the target width with your chosen fill. Perfect for formatting ASCII tables, code comments, plaintext documents, and terminal output.
Features
- Left, center, and right alignment modes
- Customizable target line width
- Custom padding character (space, dot, dash, custom)
- Trim leading/trailing whitespace before padding option
- Real-time preview as you type
- Copy padded text to clipboard
- 100% private — browser-only processing
How to use this tool
The Text Alignment & Padding works right in your browser — no signup, no installation. Follow these steps:
- Paste your text lines into the input area.
- Choose alignment: Left, Center, or Right.
- Set the target line width and optional padding character.
- View the aligned output instantly and click Copy to save.
Frequently asked questions
What is the padding character?
The padding character is the character used to fill the space between the text and the target width. Spaces are the default, but you can use dots, dashes, or any custom character for visual effects like dotted lines.
What happens if a line is longer than the target width?
Long lines are preserved. The effective width expands to the longest input line if it exceeds your target, so shorter lines are padded to that expanded width.
Can I align multiple lines to different widths?
The tool uses a single target width for all lines. If you set it to 60, every line will be padded to 60 characters. You can trim lines first if needed.
Using the results
Bulk text edits that would take ages by hand happen in one step with the Text Alignment & Padding. It applies your changes the moment you make them, entirely in the browser, so your content stays on your device and the result is ready to copy immediately.