Skip to main content Accessibility Feedback

Numbers

Math.random()

Returns a random float (decimal) between 0 and 1.

This is not cryptographically secure. Do not use it for anything security related.

// returns random decimal
Math.random();