CSV viewer: open big CSV and TSV files without Excel
Drop a comma-, tab-, semicolon- or pipe-separated file. viewhack finds the delimiter and the header row, counts every row, works out each column's type and shows the rows in a grid that only draws what is on screen. A 500 MB export opens without freezing the tab.
The file is read on your device. It is never uploaded.
What it shows
- The delimiter it chose and why, for example "100% of the first 200 rows have 7 fields". The same goes for the header row. You can override both.
- The exact row count: data rows, not counting the header. Line breaks inside quoted cells do not start a new row, and empty lines are skipped.
- Each column's type (number, date, text or empty), judged from every row in the file, not a sample. A column counts as a number only if every non-empty cell is one. Dates are recognised in ISO form (2024-03-14, optionally with a time).
- Sorting: click a column name. Numbers sort as numbers, text in natural order (so "item 9" comes before "item 10"), and empty cells always go last. The # column keeps each row's original row number.
- Cells exactly as written. Leading zeros stay (
00742), long IDs stay whole (4111111111111111) and1-2stays text. Excel changes all three.
Why not just open it in Excel?
Excel stops at 1,048,576 rows and warns that the file was "not loaded completely". The rest is simply left out. Google Sheets stops at 10 million cells, so a 1-million-row file with 11 columns is already too big. Both also convert values as they load. viewhack reads to the last row and shows what the file really contains. When you need to change data, use a spreadsheet or a database. When you need to see what is in a file, or check it before importing, this is quicker.
How it stays fast on huge files
A background thread (a Web Worker) reads the file in 4 MB slices, so the page never stops responding. After the first slice the rows appear, while counting continues. The worker keeps only where each row starts, 8 bytes per row, so a 10-million-row file needs about 80 MB of memory. It also re-reads just the rows on screen as you scroll. The site's automated test builds a 105 MB, 2.9-million-row CSV in headless Chrome and opens it. It requires the first rows within 10 seconds and no pause of the page longer than a second. On the test server, the first rows appeared after about 0.2 seconds and every row was counted in about 1 second.
Sorting needs the whole column in memory and is available up to 1,000,000 rows. Bigger files stay in file order, and the page says so.
What it cannot open
- UTF-16 text, which is what Excel's "Unicode Text" export writes. viewhack names it and asks you to re-save as UTF-8 (in Excel: CSV UTF-8).
- Spreadsheets (.xlsx, .xls, .ods) are not CSV. They open in the spreadsheet viewer, which shows every sheet and saves any of them as CSV. Apple Numbers files are recognised as ZIP archives only.
- Fixed-width text, where columns are lined up with spaces, opens as a single column.
- Other delimiters (such as
^or the ASCII unit separator) cannot be detected or chosen. Only comma, tab, semicolon and pipe are supported. - Single quotes are not treated as quoting. Only
"is, as in RFC 4180. - Preamble lines above the header (common in bank exports) can mislead the detection. Choose the delimiter and header manually.
- Dates like 03/14/2024 or 14.03.2024 count as text, because the day and month order cannot be known for sure. Decimal commas (
3,50) count as numbers only when the delimiter is not a comma. - A quote that never closes swallows everything after it. Reading stops with a message if a single row passes 64 MB.