How does it work?
This tool left-aligns text by removing all leading whitespace (spaces, tabs) from each line. This ensures that each line starts at the leftmost position without any indentation.
The process works as follows:
- The text is split into individual lines
- For each line, all leading whitespace characters are removed
- The lines are joined back together, preserving line breaks
Example
Original text (with leading spaces)
Title
Subtitle
This is a line with some leading spaces
Short line
Another line with leading whitespace
The EndAfter left alignment
Title
Subtitle
This is a line with some leading spaces
Short line
Another line with leading whitespace
The EndParameters
- Text to left-align: The input text with leading whitespace that you want to left-align
This tool is useful for:
- Cleaning up text copied from sources with inconsistent indentation
- Removing unwanted indentation from code snippets
- Standardizing text formatting in documents
- Preparing text for further processing or formatting
- Fixing alignment issues in plain text files
Note: This tool only removes leading whitespace. It does not affect whitespace between words or at the end of lines.
Related Tools
- Align Center - Center text between margins
- Align Right - Align text to the right margin
- Align Carets - Align text at specific positions marked by carets
- Trim Leading - Remove leading whitespace from each line
- Trim Whitespaces - Remove both leading and trailing whitespace
All Tools
See all available tools