Format and Align Markdown Tables
Re-align a Markdown table's columns so that pipes and content line up perfectly in the source file.
Detailed Explanation
Perfecting Markdown Table Alignment
Markdown tables use pipes (|) and hyphens (-) to define columns and the header separator. While Markdown renderers do not require the pipes to be aligned, having them line up in the source makes the file much easier to edit and review in a text editor or during code review.
Before
| Feature | Status | Priority | Owner |
| --- | --- | --- | --- |
| Dark mode | Done | High | Alice |
| Export to PDF | In Progress | Medium | Bob |
| API v2 | Planned | Low | Charlie |
| Mobile responsive | Done | High | Diana |
After
| Feature | Status | Priority | Owner |
| --- | --- | --- | --- |
| Dark mode | Done | High | Alice |
| Export to PDF | In Progress | Medium | Bob |
| API v2 | Planned | Low | Charlie |
| Mobile responsive | Done | High | Diana |
Steps
- Load the Markdown Table preset or paste your table into the input.
- The input delimiter is set to Pipe |.
- Output delimiter remains Pipe |.
- Trim whitespace is enabled to normalize cell padding.
- Columns are left-aligned by default. Switch numeric or status columns to center or right alignment as needed.
The Separator Row
The --- separator row is treated as a regular data row. It will be padded with spaces to match the column width. This is visually correct because Markdown renderers ignore the exact number of hyphens — only the presence of the separator matters.
Integration
After aligning, you can paste the result directly back into your Markdown file. The Markdown Table Generator tool can create a new table from scratch, while this tool perfects the alignment of an existing one.
Use Case
A technical writer is editing a Markdown documentation file and wants every table in the source to have perfectly aligned pipes for consistency.