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
Test name
Executions per second
Object.entries with URLSearchParams
221964.5 Ops/sec
Json Parse
2110737.0 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);