Toggle navigation
MeasureThat
.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
Json vs Url Params parsing.
Compares the performance of parsing data send in the body as json vs data send in the url as params.
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:135.0) Gecko/20100101 Firefox/135.0
Browser:
Firefox 135
Operating system:
Windows
Device Platform:
Desktop
Date tested:
one year ago
Json Parse
2.1M/s
Object.entries with URLSearchParams
222K/s
View exact numbers
Test name
Executions per second
✓
Json Parse
2,110,737 Ops/sec
Object.entries with URLSearchParams
221,964 Ops/sec
Script Preparation code:
var query = 'test=1&test=2&alt=test&b=8&c=9&alt=9'; var body = '{"test": [1, 2], "alt": ["test",9], "b":8,"c": 9}';
Tests:
Object.entries with URLSearchParams
var result = Object.fromEntries(new URLSearchParams(query));
Json Parse
var result = JSON.parse(body);