This class provides a simple info box that will help you monitor your code performance.

var stats = new Stats();
stats.setMode(1); // 0: fps, 1: ms
// Align top-left
stats.domElement.style.position = 'absolute';
stats.domElement.style.left = '0px';
stats.domElement.style.top = '0px';
document.body.appendChild( stats.domElement );
setInterval( function () {
stats.begin();
// your code goes here
stats.end();
}, 1000 / 60 );
Albeit theorically not as accurate the widget can also be easily inserted to any site using a bookmarklet. Follow the instructions.
2012 09 01 - r11 (2,243 KB, gzip: 903 B)
build/Stats.js to build/stats.min.js.2012 05 10 - r10 (2,243 KB, gzip: 903 B)
.getDomElement() to .domElement back..getFps(), .getFpsMin(), .getFpsMax(), .getMs(), .getMsMin(), .getMsMax()..begin() and .end()..setMode().2012 01 18 - r9 (2,872 KB, gzip: 1,038 KB)
.domElement to .getDomElement().getFps(), .getFpsMin(), .getFpsMax(), .getMs(), .getMsMin(), .getMsMax().2011 10 16 - r8 (2.670 KB, gzip: 987 B)
2011 10 13 - r7 (4.083 KB, gzip: 1.377 KB)
new Date().getTime() with Date.now().2011 05 28 - r6 (4.103 KB, gzip: 1.384 KB)
2010 09 21 - r5 (3.800 KB)
2010 06 11 - r4 (2.235 KB)
2010 05 12 - r3 (1.241 KB)
position = 'absolute'.2010 03 01 - r2 (2.177 KB)
2010 02 21 - r1
2009 08 09 - r0