convert-csv.com logo convert-csv.com

Convert Fixed Width Text to CSV / Excel

Parse fixed-width / column-aligned text files into CSV or Excel by defining field widths. Runs entirely client-side.

100% Secure - your files are processed in your browser and never sent to a server.
Drop your file hereor click to browseSupports Text files (.txt) (Max 100MB)

Fixed-width text files store tabular data by aligning columns to specific character positions rather than using delimiters. Each field occupies a predetermined number of characters, and shorter values are padded with spaces. This format was standard in mainframe computing and remains common in banking, insurance, and government data exchanges. Converting fixed-width text to CSV requires knowing (or auto-detecting) where each column starts and ends. This tool parses fixed-width files entirely in your browser. You can either specify column widths as comma-separated values (e.g., 10,20,15) or define split positions (e.g., 10,30,45). If you leave the column definition empty, the parser attempts to auto-detect column boundaries by analyzing consistent spacing patterns in the data. The converter handles both padded and unpadded fixed-width formats, and you can select the output delimiter for the resulting CSV. All processing runs locally using Web Workers, so your data stays on your device. The tool supports files up to 100 MB and produces clean, properly quoted CSV output that is ready for import into databases, spreadsheets, or data pipelines.

How to use the Convert Fixed Width to CSV tool

  1. Load your data: Drag and drop your fixed-width text file, choose a file from your file explorer, or paste your data directly into the paste area.
  2. Configure column parsing: Enter comma-separated column widths (e.g. 10,20,15) or split positions (e.g. 10,30,45). Leave blank to auto-detect columns.
  3. Adjust output settings: Choose an output delimiter (comma, semicolon, tab, or pipe) and toggle whether the first row is a header.
  4. Convert to CSV: Click the "Convert Data" button to parse the fixed-width text into structured CSV.
  5. Export results: Copy the results to your clipboard, download as a local file, or export to Excel format.

Frequently asked questions

How do I know what column widths to enter for my fixed-width file?
You can inspect the file in a plain text editor and count the character positions where columns align. Alternatively, leave the column definition blank and the parser will attempt to auto-detect column boundaries by analyzing consistent spacing patterns across rows.
Does this tool handle fixed-width files with mixed data types?
Yes. The parser treats each field as text, preserving numbers, dates, and string values exactly as they appear in the source file. No type coercion is applied during conversion.
Can I convert fixed-width data with no padding (ragged columns)?
Yes. The tool handles both padded (space-filled) and unpadded fixed-width formats. When using auto-detection, it identifies column boundaries based on the pattern of spaces between non-space characters.
What output delimiters are available?
You can output the CSV with comma, semicolon, tab, or pipe delimiters. The default is comma, which produces standard RFC 4180 compliant CSV.
Is there a file size limit for fixed-width conversion?
The tool processes files up to 100 MB entirely in your browser. For very large files, the Web Worker keeps the interface responsive while parsing runs in the background.

Related tools