Get to know MDN better
This feature is well established and works across many devices and browser versions. It’s been available across browsers since July 2015.
The Math.SQRT1_2 static data property represents the square root of 1/2, which is approximately 0.707.
| Writable | no |
| Enumerable | no |
| Configurable | no |
Math.SQRT1_2 is a constant and a more performant equivalent to Math.sqrt(0.5).
Because SQRT1_2 is a static property of Math, you always use it as Math.SQRT1_2, rather than as a property of a Math object you created (Math is not a constructor).
The following function calculates the side length of a square given its diagonal length:
| ECMAScript® 2027 Language Specification # sec-math.sqrt1_2 |
Enable JavaScript to view this browser compatibility table.
This page was last modified on Nov 3, 2025 by MDN contributors.
Your blueprint for a better internet.
Visit Mozilla Corporation’s not-for-profit parent, the Mozilla Foundation.
Portions of this content are ©1998–2026 by individual mozilla.org contributors. Content available under a Creative Commons license.