HTML | Navigator appCodeName Property
The Navigator appCodeName Property is used for returning the code name of the browser. It is a read-only property and generally, all modern browsers return “Mozilla”.
Syntax:
navigator.appCodeName
Return values: Returns a string that represents the code name of the browser.
Below program illustrates the Navigator appCodeName Property:
1. Getting the code name of the browser.
<!DOCTYPE html> <html> <head> <title> Navigator appCodeName Property in HTML </title> <style> h1 { color: green; } h2 { font-family: Impact; } body { text-align: center; } </style> </head> <body> <h1>GeeksforGeeks</h1> <h2>Navigator appCodeName Property</h2> <p> For returning the codename of the current browser, double click the "Return Browser Codename" button: </p> <button ondblclick="codename()"> Return Browser Codename </button> <p id="BrowserName"></p> <script> function codename() { var b = "Browser's CodeName : " + navigator.appCodeName; document.getElementById("BrowserName").innerHTML = b; } </script> </body> </html> |
Output:

After clicking the button

Supported Browsers: The browser supported by Navigator appCodeName Property listed below:
- Google Chrome
- Internet Explorer
- Firefox
- Opera
- Safari
Recommended Posts:
- HTML | Navigator platform Property
- HTML | Navigator appVersion Property
- HTML | Navigator appName Property
- HTML | Navigator cookieEnabled Property
- HTML | Navigator geolocation Property
- HTML | Navigator product Property
- HTML | Navigator onLine Property
- HTML | Navigator language Property
- HTML | Navigator userAgent Property
- HTML | DOM Navigator taintEnabled() Method
- HTML | Navigator javaEnabled( ) Method
- Web Vibration API | Navigator.vibrate() Method
- HTML | DOM value Property
- HTML | DOM specified Property
- HTML | DOM Bdo dir Property
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.



