Tests:

Historical Performance Data aggregated from 5 community runs

Desktop Results:
Chrome 5 runs
Array.prototype.slice
145.5M/s
Array.prototype.slice(0)
143.5M/s
spread operator
113.9M/s

Fastest: Array.prototype.slice (1.3x faster)

View exact numbers
  • Array.prototype.slice: 145,540,992 ops/sec
  • Array.prototype.slice(0): 143,522,688 ops/sec
  • spread operator: 113,853,056 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
    Array.prototype.slice
    spread operator
    Array.prototype.slice(0)

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: one year ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36 Edg/138.0.0.0
Chrome 138 on Windows
View result in a separate tab
Array.prototype.slice(0)
149.6M/s
Array.prototype.slice
147.6M/s
spread operator
115.5M/s
View exact numbers
Test name Executions per second
Array.prototype.slice(0) 149,604,608 Ops/sec
Array.prototype.slice 147,644,464 Ops/sec
spread operator 115,473,520 Ops/sec