Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
JavaScript search() vs indexOf()
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Android 15; Mobile; rv:140.0) Gecko/140.0 Firefox/140.0
Browser:
Firefox Mobile 140
Operating system:
Android
Device Platform:
Mobile
Date tested:
one year ago
Test name
Executions per second
search()
39272532.0 Ops/sec
indexOf()
1720783104.0 Ops/sec
Tests:
search()
const str = 'This is a test'; str.search('test');
indexOf()
const str = 'This is a test'; str.indexOf('test');