Matt Borja

Password Generator

A JavaScript-based password generator executed only in your browser (no network)

Generate Password

How it works

The below JavaScript snippet generates N bytes of random sequence sourced client-side from window.crypto and finally Base64 encoded.

var N = 32;
var rng = window.crypto || window.msCrypto;
var bytes = Array
              .from(rng.getRandomValues(new Uint8Array(N)))
              .map(c => String.fromCharCode(c))

var encoded = btoa(bytes);

Additional reading