Easy Tutorial
❮ Prop Win Pagexoffset Prop Style Bottom ❯

JavaScript MAX_VALUE Property

JavaScript Number Object

Example

Return the largest number in JavaScript:

Number.MAX_VALUE;

Return Value:

Since MAX_VALUE is a property of the Number object, it can be accessed using Number.MAX_VALUE.

Using a custom Number object x (x.MAX_VALUE) will not work.


Definition and Usage

The MAX_VALUE property represents the largest number that can be represented in JavaScript.

Its approximate value is 1.7976931348623157 x 10^308.

Note: Numbers greater than MAX_VALUE are represented as infinity.


Using Number.MAX_VALUE

MAX_VALUE is a static property of the JavaScript Number object and can only be accessed through Number.MAX_VALUE.

Using a custom Number object x (x.MAX_VALUE) will not work.

Example

x Output:


Browser Support

All major browsers support the MAX_VALUE property.


Syntax

Technical Details

Return Value: Largest number, 1.7976931348623157e+308
JavaScript Version: 1.1
--- ---

JavaScript Number Object

❮ Prop Win Pagexoffset Prop Style Bottom ❯