.NET CSV benchmark

Benchmark source
Test last run 05/01/2026
reddit_subset.csv
5.2 MB (UTF-8), 10.5 MB (UTF-16)[22 columns, 16,781 rows]
'RC_2008-01.ndjson' from the Arctic Shift reddit dump converted to CSV format. Meant to represent real-world data processing, and contains a very diverse range of long, complex text.
mixed_unicode.csv
5.5 MB (UTF-8), 8.0 MB (UTF-16)[4 columns, 52,524 rows]
'item_flavor_text.csv' from the Veekun/pokedex GitHub repo. Contains medium-length text in many different languages & scripts, with many newlines.
65K_Records_Data.csv
7.9 MB (UTF-8), 15.7 MB (UTF-16)[14 columns, 65,535 rows]
Example CSV dataset used by MarkPflug/Benchmarks to benchmark .NET CSV libraries. Contains sample financial record data.
synthetic_thin_numeric.csv
916.9 KB (UTF-8), 1.8 MB (UTF-16)[4 columns, 50,000 rows]
An artificially generated dataset consisting of 4 columns containing integers ranging from 0 - 2000.
synthetic_short_numeric.csv
969 B (UTF-8), 1.9 KB (UTF-16)[4 columns, 50 rows]
An artificially generated dataset consisting of 4 columns containing integers ranging from 0 - 2000. Short to show overall library overhead.
synthetic_quoted_numeric.csv
1.3 MB (UTF-8), 2.6 MB (UTF-16)[4 columns, 50,000 rows]
An artificially generated dataset consisting of 4 columns containing integers ranging from 0 - 2000, with each column wrapped in quotation marks for escaping.
synthetic_complex.csv
70.3 MB (UTF-8), 134.3 MB (UTF-16)[4 columns, 50,000 rows]
An artificially generated dataset consisting of 1 column with a number, and 3 containing very large escaped text designed to be extremely challenging for a parser to scan through.
Benchmark environment:
BenchmarkDotNet v0.15.8, Windows 10 (10.0.19044.6575/21H2/November2021Update)
AMD Ryzen 7 9700X 3.80GHz, 1 CPU, 16 logical and 8 physical cores
.NET SDK 10.0.101
  [Host] : .NET 10.0.1 (10.0.1, 10.0.125.57005), X64 RyuJIT x86-64-v4
                
Tests come in two variants:
  • UTF-8: Loaded binary CSV as UTF-8 data read from a Stream. Sylvan.Data.Csv does not directly support this, and is emulated by passing it through a StreamReader.
  • UTF-16: Loaded CSV as UTF-16 data read from a TextReader.
    If you parse a CSV with the source as a string / Span<char>, you will be using this version.
    Note that while libraries using this seem to have faster raw MB/s speed, it's not necessarily processing more data faster; on average UTF-16 versions of UTF-8 data is double the physical byte size. Use Mean as an unbiased reference if you want to measure actual parse time

Test suite #1 - Skip to end

Measures how fast a parser can read from start to finish, without extracting any values and only interpreting structure. Mimics workloads like:
  • Counting the amount of lines and fields in a CSV
  • Validating column count
UTF8
LibrarySpeedMeanErrorAllocations
#1FourLambda.Csv4,213.46 MB/s±3.84 MB/s1,245.140 µs1.135 µs0.64 KB
#2Sep3,934.85 MB/s±1.77 MB/s1,333.304 µs0.600 µs6.58 KB
#3Sylvan.Data.Csv1,088.63 MB/s±1.12 MB/s4,819.209 µs4.976 µs77.04 KB
#4NReco1,047.41 MB/s±2.37 MB/s5,008.895 µs11.352 µs84.91 KB
#5CsvHelper565.40 MB/s±0.62 MB/s9,279.084 µs10.172 µs72.28 KB
UTF16
LibrarySpeedMeanErrorAllocations
#1Sep8,160.25 MB/s±20.52 MB/s1,285.392 µs3.233 µs3.28 KB
#2FourLambda.Csv6,954.56 MB/s±22.80 MB/s1,508.236 µs4.946 µs0.62 KB
#3Sylvan.Data.Csv2,167.21 MB/s±4.30 MB/s4,839.910 µs9.593 µs74.08 KB
#4NReco2,137.50 MB/s±5.70 MB/s4,907.190 µs13.092 µs81.61 KB
#5CsvHelper1,144.64 MB/s±1.58 MB/s9,163.673 µs12.650 µs68.98 KB

Test suite #2 - Column sum

Measures how fast a single column can be parsed as an int32 and compute a sum. Mimics workloads like:
  • Calculating a sum / min / max across transactions
  • Determining the maximum ID of a dataset of records
UTF8
LibrarySpeedMeanErrorAllocations
#1FourLambda.Csv3,934.93 MB/s±9.60 MB/s1,333.275 µs3.253 µs0.65 KB
#2Sep3,626.02 MB/s±3.55 MB/s1,446.862 µs1.416 µs6.57 KB
#3Sylvan.Data.Csv1,072.36 MB/s±1.41 MB/s4,892.356 µs6.437 µs77.04 KB
#4NReco1,003.88 MB/s±2.74 MB/s5,226.069 µs14.286 µs500.26 KB
#5CsvHelper519.84 MB/s±1.07 MB/s10,092.176 µs20.681 µs1,274.87 KB
UTF16
LibrarySpeedMeanErrorAllocations
#1Sep7,551.89 MB/s±8.87 MB/s1,388.939 µs1.631 µs3.28 KB
#2FourLambda.Csv6,313.79 MB/s±12.83 MB/s1,661.305 µs3.376 µs0.62 KB
#3Sylvan.Data.Csv2,149.64 MB/s±2.03 MB/s4,879.480 µs4.611 µs74.08 KB
#4NReco2,033.50 MB/s±2.36 MB/s5,158.170 µs5.991 µs496.96 KB
#5CsvHelper1,047.42 MB/s±1.51 MB/s10,014.246 µs14.406 µs1,271.57 KB

Test suite #3 - Read all columns

Measures how fast a parser can get the text content of every column. Has 3 variants:
  • "string": Reads the column value as a string object
  • "span": Reads the column value as a Span<char> object. Not available in the UTF-8 version of FourLambda.Csv
  • "span-raw": Reads the column value as a Span<char> / Span<byte> object, without performing any unescaping. Not available in Sylvan.Data.Csv
string / UTF8
LibrarySpeedMeanErrorAllocations
#1Sep1,031.48 MB/s±5.06 MB/s5,086.238 µs24.972 µs16.15 MB
#2FourLambda.Csv671.82 MB/s±2.42 MB/s7,809.193 µs28.140 µs17.93 MB
#3Sylvan.Data.Csv576.33 MB/s±2.03 MB/s9,102.983 µs32.021 µs18.11 MB
#4NReco555.64 MB/s±2.63 MB/s9,442.045 µs44.671 µs20.23 MB
#5CsvHelper357.35 MB/s±0.94 MB/s14,681.397 µs38.818 µs18.06 MB
string / UTF16
LibrarySpeedMeanErrorAllocations
#1Sep2,088.17 MB/s±7.70 MB/s5,023.126 µs18.532 µs16.14 MB
#2FourLambda.Csv2,007.17 MB/s±8.93 MB/s5,225.835 µs23.241 µs17.93 MB
#3Sylvan.Data.Csv1,161.66 MB/s±3.02 MB/s9,029.427 µs23.448 µs18.11 MB
#4NReco1,123.55 MB/s±5.16 MB/s9,335.678 µs42.913 µs20.23 MB
#5CsvHelper718.35 MB/s±1.87 MB/s14,601.614 µs38.018 µs18.06 MB
span / UTF8
LibrarySpeedMeanErrorAllocations
#1Sep2,311.40 MB/s±0.42 MB/s2,269.776 µs0.411 µs6.59 KB
#2FourLambda.Csv1,142.12 MB/s±1.50 MB/s4,593.532 µs6.050 µs0.68 KB
#3Sylvan.Data.Csv900.14 MB/s±1.18 MB/s5,828.399 µs7.629 µs178.52 KB
span / UTF16
LibrarySpeedMeanErrorAllocations
#1FourLambda.Csv5,240.63 MB/s±3.60 MB/s2,001.500 µs1.375 µs0.63 KB
#2Sep4,698.56 MB/s±7.60 MB/s2,232.410 µs3.613 µs3.29 KB
#3Sylvan.Data.Csv1,790.83 MB/s±4.93 MB/s5,857.138 µs16.128 µs175.56 KB
span-raw / UTF8
LibrarySpeedMeanErrorAllocations
#1FourLambda.Csv3,809.30 MB/s±1.69 MB/s1,377.249 µs0.612 µs0.65 KB
#2Sep3,395.33 MB/s±2.79 MB/s1,545.167 µs1.269 µs6.57 KB
span-raw / UTF16
LibrarySpeedMeanErrorAllocations
#1Sep7,059.28 MB/s±20.21 MB/s1,485.862 µs4.253 µs3.28 KB
#2FourLambda.Csv6,380.35 MB/s±19.20 MB/s1,643.972 µs4.948 µs0.62 KB

Test suite #4 - Composite workload

Measures how fast a parser can extract strongly-typed values from rows, e.g. extracting a decimal from a decimal formatted column, and a DateTime from a datetime formatted column.
Not available for this dataset