js vs eval vs json

JavaScript performance comparison

Test case created by gartz

Test runner

Warning! For accurate results, please disable Firebug before running the tests. (Why?)

Java applet disabled.

Testing in CCBot 2.0.0 / Other 0.0.0
Test Ops/sec
native
const obj = [{"_id":"5d13e90e388162dad3fb0b1a","index":0,"guid":"9a1ce5cf-c449-4a63-af4b-211f9bc1de15","isActive":true,"balance":"$3,591.95","picture":"http://placehold.it/32x32","age":30,"eyeColor":"green","name":"Summers Cross","gender":"male","company":"JIMBIES","email":"summerscross@jimbies.com","phone":"+1 (894) 449-2326","address":"980 Kenilworth Place, Vallonia, Virgin Islands, 2656","registered":"2017-07-30T01:03:40 +07:00","latitude":46.410974,"longitude":-45.520726,"tags":["laborum","cillum","sunt","nostrud","in","ut","consectetur"],"friends":[{"id":0,"name":"Turner Lowe"},{"id":1,"name":"Smith Holman"},{"id":2,"name":"Berger Henson"}],"greeting":"Hello, Summers Cross! You have 1 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90e804b44d18dd492dd","index":1,"guid":"d65686e3-48f0-4f1f-8264-83475dbee3fb","isActive":false,"balance":"$2,619.36","picture":"http://placehold.it/32x32","age":28,"eyeColor":"brown","name":"York Poole","gender":"male","company":"LIMOZEN","email":"yorkpoole@limozen.com","phone":"+1 (880) 534-2711","address":"520 Granite Street, Alafaya, Guam, 7100","registered":"2018-06-28T10:21:00 +07:00","latitude":7.169371,"longitude":-108.374691,"tags":["mollit","aliqua","cupidatat","est","eiusmod","laboris","et"],"friends":[{"id":0,"name":"Jeanne Hays"},{"id":1,"name":"Barlow Gallagher"},{"id":2,"name":"Lester Adams"}],"greeting":"Hello, York Poole! You have 5 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90e5b3a869a14c8f5b1","index":2,"guid":"f9ba2d2a-d44e-4c8b-aa25-8b579a14e013","isActive":true,"balance":"$3,772.58","picture":"http://placehold.it/32x32","age":40,"eyeColor":"green","name":"Ethel Olsen","gender":"female","company":"ACRUEX","email":"ethelolsen@acruex.com","phone":"+1 (910) 594-2044","address":"914 Jaffray Street, Sunwest, Hawaii, 2414","registered":"2019-05-25T04:17:52 +07:00","latitude":-52.246322,"longitude":146.166837,"tags":["amet","duis","eiusmod","in","deserunt","Lorem","velit"],"friends":[{"id":0,"name":"Viola Dawson"},{"id":1,"name":"Mosley Logan"},{"id":2,"name":"Ollie Murray"}],"greeting":"Hello, Ethel Olsen! You have 8 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90ee8585fe274c2e265","index":3,"guid":"843d036b-5b9e-445c-a283-f90807e61856","isActive":true,"balance":"$3,842.28","picture":"http://placehold.it/32x32","age":23,"eyeColor":"green","name":"Jeannette Rowe","gender":"female","company":"DIGIGEN","email":"jeannetterowe@digigen.com","phone":"+1 (816) 509-3573","address":"619 Cyrus Avenue, Emory, New Mexico, 4047","registered":"2016-03-04T01:33:04 +08:00","latitude":29.925077,"longitude":-120.268713,"tags":["qui","eiusmod","aute","labore","deserunt","ad","laboris"],"friends":[{"id":0,"name":"Goodman Robles"},{"id":1,"name":"Ashlee Workman"},{"id":2,"name":"Marva Caldwell"}],"greeting":"Hello, Jeannette Rowe! You have 2 unread messages.","favoriteFruit":"apple"},{"_id":"5d13e90ebd991ee67a0c0115","index":4,"guid":"4bea5f02-17c4-4429-8409-21d29e8dc9eb","isActive":true,"balance":"$2,247.76","picture":"http://placehold.it/32x32","age":33,"eyeColor":"brown","name":"Deidre Petersen","gender":"female","company":"PERMADYNE","email":"deidrepetersen@permadyne.com","phone":"+1 (925) 423-2593","address":"761 Middagh Street, Herbster, Vermont, 3109","registered":"2016-06-11T08:42:34 +07:00","latitude":68.97901,"longitude":30.853816,"tags":["enim","consequat","aute","cupidatat","labore","voluptate","eiusmod"],"friends":[{"id":0,"name":"Wilkinson Hayes"},{"id":1,"name":"Olivia Velasquez"},{"id":2,"name":"Freida Owen"}],"greeting":"Hello, Deidre Petersen! You have 10 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90eec52857c9d2debd5","index":5,"guid":"151d52c7-e95d-4723-840b-914c533d5a0c","isActive":true,"balance":"$3,219.19","picture":"http://placehold.it/32x32","age":28,"eyeColor":"green","name":"England Strong","gender":"male","company":"PANZENT","email":"englandstrong@panzent.com","phone":"+1 (844) 437-3186","address":"405 Grand Street, Nipinnawasee, Alabama, 3379","registered":"2017-03-09T12:43:20 +08:00","latitude":86.315101,"longitude":110.52914,"tags":["deserunt","enim","est","nulla","ad","et","velit"],"friends":[{"id":0,"name":"Francis Landry"},{"id":1,"name":"Claire Robertson"},{"id":2,"name":"Josefina Brewer"}],"greeting":"Hello, England Strong! You have 1 unread messages.","favoriteFruit":"apple"},{"_id":"5d13e90eca136b3de63a16a3","index":6,"guid":"83a10c8c-9eae-4472-91c1-c080188849fd","isActive":true,"balance":"$2,228.31","picture":"http://placehold.it/32x32","age":34,"eyeColor":"green","name":"Mcgee Hunter","gender":"male","company":"EXOSPEED","email":"mcgeehunter@exospeed.com","phone":"+1 (933) 449-2174","address":"771 Metropolitan Avenue, Machias, Pennsylvania, 8819","registered":"2017-09-27T02:43:21 +07:00","latitude":26.646393,"longitude":-24.540479,"tags":["consequat","magna","eu","aliqua","mollit","proident","in"],"friends":[{"id":0,"name":"Rosario Houston"},{"id":1,"name":"Kerry Wood"},{"id":2,"name":"Pollard Briggs"}],"greeting":"Hello, Mcgee Hunter! You have 4 unread messages.","favoriteFruit":"strawberry"}];
pending…
json
const obj = JSON.parse(`[{"_id":"5d13e90e388162dad3fb0b1a","index":0,"guid":"9a1ce5cf-c449-4a63-af4b-211f9bc1de15","isActive":true,"balance":"$3,591.95","picture":"http://placehold.it/32x32","age":30,"eyeColor":"green","name":"Summers Cross","gender":"male","company":"JIMBIES","email":"summerscross@jimbies.com","phone":"+1 (894) 449-2326","address":"980 Kenilworth Place, Vallonia, Virgin Islands, 2656","registered":"2017-07-30T01:03:40 +07:00","latitude":46.410974,"longitude":-45.520726,"tags":["laborum","cillum","sunt","nostrud","in","ut","consectetur"],"friends":[{"id":0,"name":"Turner Lowe"},{"id":1,"name":"Smith Holman"},{"id":2,"name":"Berger Henson"}],"greeting":"Hello, Summers Cross! You have 1 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90e804b44d18dd492dd","index":1,"guid":"d65686e3-48f0-4f1f-8264-83475dbee3fb","isActive":false,"balance":"$2,619.36","picture":"http://placehold.it/32x32","age":28,"eyeColor":"brown","name":"York Poole","gender":"male","company":"LIMOZEN","email":"yorkpoole@limozen.com","phone":"+1 (880) 534-2711","address":"520 Granite Street, Alafaya, Guam, 7100","registered":"2018-06-28T10:21:00 +07:00","latitude":7.169371,"longitude":-108.374691,"tags":["mollit","aliqua","cupidatat","est","eiusmod","laboris","et"],"friends":[{"id":0,"name":"Jeanne Hays"},{"id":1,"name":"Barlow Gallagher"},{"id":2,"name":"Lester Adams"}],"greeting":"Hello, York Poole! You have 5 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90e5b3a869a14c8f5b1","index":2,"guid":"f9ba2d2a-d44e-4c8b-aa25-8b579a14e013","isActive":true,"balance":"$3,772.58","picture":"http://placehold.it/32x32","age":40,"eyeColor":"green","name":"Ethel Olsen","gender":"female","company":"ACRUEX","email":"ethelolsen@acruex.com","phone":"+1 (910) 594-2044","address":"914 Jaffray Street, Sunwest, Hawaii, 2414","registered":"2019-05-25T04:17:52 +07:00","latitude":-52.246322,"longitude":146.166837,"tags":["amet","duis","eiusmod","in","deserunt","Lorem","velit"],"friends":[{"id":0,"name":"Viola Dawson"},{"id":1,"name":"Mosley Logan"},{"id":2,"name":"Ollie Murray"}],"greeting":"Hello, Ethel Olsen! You have 8 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90ee8585fe274c2e265","index":3,"guid":"843d036b-5b9e-445c-a283-f90807e61856","isActive":true,"balance":"$3,842.28","picture":"http://placehold.it/32x32","age":23,"eyeColor":"green","name":"Jeannette Rowe","gender":"female","company":"DIGIGEN","email":"jeannetterowe@digigen.com","phone":"+1 (816) 509-3573","address":"619 Cyrus Avenue, Emory, New Mexico, 4047","registered":"2016-03-04T01:33:04 +08:00","latitude":29.925077,"longitude":-120.268713,"tags":["qui","eiusmod","aute","labore","deserunt","ad","laboris"],"friends":[{"id":0,"name":"Goodman Robles"},{"id":1,"name":"Ashlee Workman"},{"id":2,"name":"Marva Caldwell"}],"greeting":"Hello, Jeannette Rowe! You have 2 unread messages.","favoriteFruit":"apple"},{"_id":"5d13e90ebd991ee67a0c0115","index":4,"guid":"4bea5f02-17c4-4429-8409-21d29e8dc9eb","isActive":true,"balance":"$2,247.76","picture":"http://placehold.it/32x32","age":33,"eyeColor":"brown","name":"Deidre Petersen","gender":"female","company":"PERMADYNE","email":"deidrepetersen@permadyne.com","phone":"+1 (925) 423-2593","address":"761 Middagh Street, Herbster, Vermont, 3109","registered":"2016-06-11T08:42:34 +07:00","latitude":68.97901,"longitude":30.853816,"tags":["enim","consequat","aute","cupidatat","labore","voluptate","eiusmod"],"friends":[{"id":0,"name":"Wilkinson Hayes"},{"id":1,"name":"Olivia Velasquez"},{"id":2,"name":"Freida Owen"}],"greeting":"Hello, Deidre Petersen! You have 10 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90eec52857c9d2debd5","index":5,"guid":"151d52c7-e95d-4723-840b-914c533d5a0c","isActive":true,"balance":"$3,219.19","picture":"http://placehold.it/32x32","age":28,"eyeColor":"green","name":"England Strong","gender":"male","company":"PANZENT","email":"englandstrong@panzent.com","phone":"+1 (844) 437-3186","address":"405 Grand Street, Nipinnawasee, Alabama, 3379","registered":"2017-03-09T12:43:20 +08:00","latitude":86.315101,"longitude":110.52914,"tags":["deserunt","enim","est","nulla","ad","et","velit"],"friends":[{"id":0,"name":"Francis Landry"},{"id":1,"name":"Claire Robertson"},{"id":2,"name":"Josefina Brewer"}],"greeting":"Hello, England Strong! You have 1 unread messages.","favoriteFruit":"apple"},{"_id":"5d13e90eca136b3de63a16a3","index":6,"guid":"83a10c8c-9eae-4472-91c1-c080188849fd","isActive":true,"balance":"$2,228.31","picture":"http://placehold.it/32x32","age":34,"eyeColor":"green","name":"Mcgee Hunter","gender":"male","company":"EXOSPEED","email":"mcgeehunter@exospeed.com","phone":"+1 (933) 449-2174","address":"771 Metropolitan Avenue, Machias, Pennsylvania, 8819","registered":"2017-09-27T02:43:21 +07:00","latitude":26.646393,"longitude":-24.540479,"tags":["consequat","magna","eu","aliqua","mollit","proident","in"],"friends":[{"id":0,"name":"Rosario Houston"},{"id":1,"name":"Kerry Wood"},{"id":2,"name":"Pollard Briggs"}],"greeting":"Hello, Mcgee Hunter! You have 4 unread messages.","favoriteFruit":"strawberry"}]`);
pending…
eval
const obj = eval(`[{"_id":"5d13e90e388162dad3fb0b1a","index":0,"guid":"9a1ce5cf-c449-4a63-af4b-211f9bc1de15","isActive":true,"balance":"$3,591.95","picture":"http://placehold.it/32x32","age":30,"eyeColor":"green","name":"Summers Cross","gender":"male","company":"JIMBIES","email":"summerscross@jimbies.com","phone":"+1 (894) 449-2326","address":"980 Kenilworth Place, Vallonia, Virgin Islands, 2656","registered":"2017-07-30T01:03:40 +07:00","latitude":46.410974,"longitude":-45.520726,"tags":["laborum","cillum","sunt","nostrud","in","ut","consectetur"],"friends":[{"id":0,"name":"Turner Lowe"},{"id":1,"name":"Smith Holman"},{"id":2,"name":"Berger Henson"}],"greeting":"Hello, Summers Cross! You have 1 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90e804b44d18dd492dd","index":1,"guid":"d65686e3-48f0-4f1f-8264-83475dbee3fb","isActive":false,"balance":"$2,619.36","picture":"http://placehold.it/32x32","age":28,"eyeColor":"brown","name":"York Poole","gender":"male","company":"LIMOZEN","email":"yorkpoole@limozen.com","phone":"+1 (880) 534-2711","address":"520 Granite Street, Alafaya, Guam, 7100","registered":"2018-06-28T10:21:00 +07:00","latitude":7.169371,"longitude":-108.374691,"tags":["mollit","aliqua","cupidatat","est","eiusmod","laboris","et"],"friends":[{"id":0,"name":"Jeanne Hays"},{"id":1,"name":"Barlow Gallagher"},{"id":2,"name":"Lester Adams"}],"greeting":"Hello, York Poole! You have 5 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90e5b3a869a14c8f5b1","index":2,"guid":"f9ba2d2a-d44e-4c8b-aa25-8b579a14e013","isActive":true,"balance":"$3,772.58","picture":"http://placehold.it/32x32","age":40,"eyeColor":"green","name":"Ethel Olsen","gender":"female","company":"ACRUEX","email":"ethelolsen@acruex.com","phone":"+1 (910) 594-2044","address":"914 Jaffray Street, Sunwest, Hawaii, 2414","registered":"2019-05-25T04:17:52 +07:00","latitude":-52.246322,"longitude":146.166837,"tags":["amet","duis","eiusmod","in","deserunt","Lorem","velit"],"friends":[{"id":0,"name":"Viola Dawson"},{"id":1,"name":"Mosley Logan"},{"id":2,"name":"Ollie Murray"}],"greeting":"Hello, Ethel Olsen! You have 8 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90ee8585fe274c2e265","index":3,"guid":"843d036b-5b9e-445c-a283-f90807e61856","isActive":true,"balance":"$3,842.28","picture":"http://placehold.it/32x32","age":23,"eyeColor":"green","name":"Jeannette Rowe","gender":"female","company":"DIGIGEN","email":"jeannetterowe@digigen.com","phone":"+1 (816) 509-3573","address":"619 Cyrus Avenue, Emory, New Mexico, 4047","registered":"2016-03-04T01:33:04 +08:00","latitude":29.925077,"longitude":-120.268713,"tags":["qui","eiusmod","aute","labore","deserunt","ad","laboris"],"friends":[{"id":0,"name":"Goodman Robles"},{"id":1,"name":"Ashlee Workman"},{"id":2,"name":"Marva Caldwell"}],"greeting":"Hello, Jeannette Rowe! You have 2 unread messages.","favoriteFruit":"apple"},{"_id":"5d13e90ebd991ee67a0c0115","index":4,"guid":"4bea5f02-17c4-4429-8409-21d29e8dc9eb","isActive":true,"balance":"$2,247.76","picture":"http://placehold.it/32x32","age":33,"eyeColor":"brown","name":"Deidre Petersen","gender":"female","company":"PERMADYNE","email":"deidrepetersen@permadyne.com","phone":"+1 (925) 423-2593","address":"761 Middagh Street, Herbster, Vermont, 3109","registered":"2016-06-11T08:42:34 +07:00","latitude":68.97901,"longitude":30.853816,"tags":["enim","consequat","aute","cupidatat","labore","voluptate","eiusmod"],"friends":[{"id":0,"name":"Wilkinson Hayes"},{"id":1,"name":"Olivia Velasquez"},{"id":2,"name":"Freida Owen"}],"greeting":"Hello, Deidre Petersen! You have 10 unread messages.","favoriteFruit":"banana"},{"_id":"5d13e90eec52857c9d2debd5","index":5,"guid":"151d52c7-e95d-4723-840b-914c533d5a0c","isActive":true,"balance":"$3,219.19","picture":"http://placehold.it/32x32","age":28,"eyeColor":"green","name":"England Strong","gender":"male","company":"PANZENT","email":"englandstrong@panzent.com","phone":"+1 (844) 437-3186","address":"405 Grand Street, Nipinnawasee, Alabama, 3379","registered":"2017-03-09T12:43:20 +08:00","latitude":86.315101,"longitude":110.52914,"tags":["deserunt","enim","est","nulla","ad","et","velit"],"friends":[{"id":0,"name":"Francis Landry"},{"id":1,"name":"Claire Robertson"},{"id":2,"name":"Josefina Brewer"}],"greeting":"Hello, England Strong! You have 1 unread messages.","favoriteFruit":"apple"},{"_id":"5d13e90eca136b3de63a16a3","index":6,"guid":"83a10c8c-9eae-4472-91c1-c080188849fd","isActive":true,"balance":"$2,228.31","picture":"http://placehold.it/32x32","age":34,"eyeColor":"green","name":"Mcgee Hunter","gender":"male","company":"EXOSPEED","email":"mcgeehunter@exospeed.com","phone":"+1 (933) 449-2174","address":"771 Metropolitan Avenue, Machias, Pennsylvania, 8819","registered":"2017-09-27T02:43:21 +07:00","latitude":26.646393,"longitude":-24.540479,"tags":["consequat","magna","eu","aliqua","mollit","proident","in"],"friends":[{"id":0,"name":"Rosario Houston"},{"id":1,"name":"Kerry Wood"},{"id":2,"name":"Pollard Briggs"}],"greeting":"Hello, Mcgee Hunter! You have 4 unread messages.","favoriteFruit":"strawberry"}]`);
pending…

You can edit these tests or add even more tests to this page by appending /edit to the URL.

Compare results of other browsers

0 Comments