
Frost crystals on glass, grown one molecule at a time. Generated image. Shows no real place.
Experiment 4
Measure it on your own device.
Experiment 4Timing
Instrument
Measured on this device, just now, by this browser. The comparison shows what this browser can do today, not what the algorithms cost in themselves. Nothing is sent anywhere.
Reading
Press Run to time each operation on this device. It takes about half a minute.
Runs in a background worker when the browser allows it, so the page stays responsive.
| Operation | Ran by | Median |
|---|---|---|
| X25519 key generation | Built in | not run |
| X25519 key exchange | Built in | not run |
| Ed25519 key generation | Built in | not run |
| Ed25519 sign | Built in | not run |
| Ed25519 verify | Built in | not run |
| ECDSA P-256 key generation | Built in | not run |
| ECDSA P-256 sign | Built in | not run |
| ECDSA P-256 verify | Built in | not run |
| RSA-2048 key generation | Built in | not run |
| RSA-2048 sign | Built in | not run |
| RSA-2048 verify | Built in | not run |
| ML-KEM-768 key generation | JS library | not run |
| ML-KEM-768 encapsulate | JS library | not run |
| ML-KEM-768 decapsulate | JS library | not run |
| ML-DSA-65 key generation | JS library | not run |
| ML-DSA-65 sign | JS library | not run |
| ML-DSA-65 verify | JS library | not run |
Your browser is not running script, so this is a finished run of the experiment.
Instrument
Measured on this device, just now, by this browser. The comparison shows what this browser can do today, not what the algorithms cost in themselves. Nothing is sent anywhere.
Reading
This experiment needs script: it runs the operations in your browser. Nothing has been measured.
Runs in a background worker when the browser allows it, so the page stays responsive.
| Operation | Ran by | Median |
|---|---|---|
| X25519 key generation | Built in | not run |
| X25519 key exchange | Built in | not run |
| Ed25519 key generation | Built in | not run |
| Ed25519 sign | Built in | not run |
| Ed25519 verify | Built in | not run |
| ECDSA P-256 key generation | Built in | not run |
| ECDSA P-256 sign | Built in | not run |
| ECDSA P-256 verify | Built in | not run |
| RSA-2048 key generation | Built in | not run |
| RSA-2048 sign | Built in | not run |
| RSA-2048 verify | Built in | not run |
| ML-KEM-768 key generation | JS library | not run |
| ML-KEM-768 encapsulate | JS library | not run |
| ML-KEM-768 decapsulate | JS library | not run |
| ML-DSA-65 key generation | JS library | not run |
| ML-DSA-65 sign | JS library | not run |
| ML-DSA-65 verify | JS library | not run |
Method
Each operation first runs twice to warm up. Then the page finds a batch size that takes at least 12 milliseconds, because browsers round their clocks to a tenth of a millisecond or more and a single fast operation would read as zero. It times up to 15 batches, or fewer when one operation passes about a second, and reports the median time of one operation. The median ignores the odd slow batch caused by the browser doing something else.
Classical schemes use the browser's own Web Cryptography API: X25519 key exchange, Ed25519, ECDSA on P-256 with SHA-256, and RSA-2048 with PKCS #1 v1.5 signatures and SHA-256. A browser that does not offer one of them shows that row as not available. Post-quantum schemes use @noble/post-quantum 0.7.1, an open-source JavaScript library under the MIT license that implements FIPS 203 (ML-KEM) and FIPS 204 (ML-DSA). Its README says it has not been independently audited and was self-audited at version 0.6.1, and that pure JavaScript makes no constant-time claim.
Built-in code is compiled into the browser; the library is JavaScript. So the comparison shows what this browser can do today with what it has, not what each algorithm costs in itself. A native post-quantum implementation would be faster. The work runs in a background worker when the browser allows it, so the page stays responsive. No request leaves the page and nothing is stored.
Sources
- W3C, Web Cryptography API (Recommendation) The built-in operations and their names. Read at its original address on .
- Paul Miller: noble-post-quantum, version 0.7.1 (MIT license), its source and README The JavaScript library for ML-KEM-768 and ML-DSA-65, its license and its audit status. Read at its original address on .
- NIST, FIPS 203: Module-Lattice-Based Key-Encapsulation Mechanism Standard (2024) ML-KEM: key generation, encapsulation, decapsulation. Read at its original address on .
- NIST, FIPS 204: Module-Lattice-Based Digital Signature Standard (2024) ML-DSA: key generation, signing, verification. Read at its original address on .
Try it on your codeThe scanner lists the cryptography a project depends on.