CSV Formatter & Column Aligner
指导
CSV Formatter & Column Aligner
Format and align CSV data with two output modes: RFC 4180 normalized CSV with proper quoting and escaping, or pretty-printed column-aligned display for human readability. Includes delimiter auto-detection, data preview table, validation, and export to JSON, Markdown table, and SQL INSERT statements.
如何使用
Paste your CSV data into the input area. Select the input delimiter (comma, tab, semicolon, pipe — or let it auto-detect). Choose an output mode: RFC 4180 for standards-compliant CSV, or Pretty-Print for aligned columns with spaces. Configure quoting style, duplicate row removal, whitespace trimming, and optional sorting. View the formatted output, check the data preview table, and export as JSON, Markdown, or SQL.
特征
- RFC 4180 Normalization — Properly quoted fields, correctly escaped embedded quotes (doubled), CRLF line endings, and consistent delimiter usage. Produces standards-compliant CSV that any parser can handle.
- Pretty-Print Alignment — Columns padded with spaces so all values align vertically. Header row highlighted with a separator line. Perfect for terminal display, documentation, or quick visual inspection of data.
- Delimiter Support — Input and output delimiter selection: comma, tab, semicolon, or pipe. Auto-detection analyzes the input to determine the most likely delimiter.
- Quoting Options — Quote all fields, quote only when needed (fields containing delimiter, quotes, or newlines), or never quote. Handles embedded quotes and multiline fields correctly.
- Data Preview — Rendered HTML table with highlighted header row, sortable columns, row and column counts.
- 验证 — Detects inconsistent column counts, unescaped quotes, empty rows, and trailing delimiters. Reports RFC 4180 compliance status.
- Data Cleaning — Remove duplicate rows, trim whitespace from cell values, sort by any column.
- Export — Copy as JSON (array of objects or array of arrays), Markdown table, or SQL INSERT statements with configurable table name.
RFC 4180 Standard
RFC 4180 defines the standard format for CSV files: fields separated by commas, records separated by CRLF, optional header row, fields containing commas/quotes/newlines must be enclosed in double quotes, and embedded double quotes are escaped by doubling them (“”). This formatter ensures your CSV output meets this standard for maximum compatibility with spreadsheets, databases, and data processing tools.
