Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

Navigator cookieEnabled Property

Navigator cookieEnabled Property

Navigator Object Reference Navigator object


Definition and Usage

The cookieEnabled property returns a Boolean value: if the browser has cookies enabled, the property value is true; if cookies are disabled, the value is false.

Syntax

navigator.cookieEnabled


Browser support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the cookieEnabled property


Example

Example

Determine whether the browser has cookies enabled:

The output of the above example is:

Try it »


More examples

This example contains all navigator properties.


Navigator Object Reference Navigator object