Tutorials Point

  JavaScript Basics
  JavaScript Objects
  JavaScript Advanced
  JS Useful References
  JS Useful Resources
  Selected Reading

Copyright © 2014 by tutorialspoint

  Home     References     Discussion Forums     About TP  

Javascript Number - MAX_VALUE

previous next AddThis Social Bookmark Button



The Number.MAX_VALUE property belongs to the static Number object. This represents constants for the largest possible positive numbers that JavaScript can work with.

This constant has actual value 1.7976931348623157 x 10308


You can access this value using the following syntax:

var val = Number.MAX_VALUE;


Here is the example showing the usage of this property.

<script type="text/javascript">
function showValue()
   var val = Number.MAX_VALUE;

   alert("Value of Number.MAX_VALUE : " + val );
<p>Click the following to see the result:</p>
<input type="button" value="Click Me" onclick="showValue();" />

This will produce following result:

Value of Number.MAX_VALUE : 1.7976931348623157 x 10308

To understand it in better way you can Try it yourself.

previous next Printer Friendly