Script Preparation code:
Tests:

Historical Performance Data aggregated from 30 community runs

Desktop Results:
Chrome 30 runs
JSON.stringify
4.3M/s
URLSearchParams
612K/s

Fastest: JSON.stringify (7.0x faster)

View exact numbers
  • JSON.stringify: 4,261,650 ops/sec
  • URLSearchParams: 612,379 ops/sec

Results show median performance across all community submissions. Run this benchmark yourself to verify on your device.

Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    JSON.stringify
    URLSearchParams

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 4 months ago)
Mozilla/5.0 (X11; Linux x86_64; rv:140.0) Gecko/20100101 Firefox/140.0
Firefox 140 on Linux
View result in a separate tab
JSON.stringify
1.5M/s
URLSearchParams
382K/s
View exact numbers
Test name Executions per second
JSON.stringify 1,542,609 Ops/sec
URLSearchParams 382,082 Ops/sec