HTML <noscript>Tag: The HTML<noscript> tag specifies an alternate content for users that have disabled scripts in their browser. The <noscript> element can be used in both <head> and <body>. When used inside the <head> element: <noscript> must contain only <link>, <style>, and <meta> elements. And the content inside the <noscript> element will be displayed if scripts are not supported, or are disabled in the user’s browser.
HTML <noscript>Tag
The HTML noscript tag supports global attributes. And in HTML 4.01 <noscript> tag can only be applied inside the <body> tag. But in HTML 5 <noscript> tag can be used both inside <head> and <body>.
Syntax: <noscript> Text </noscript>
Browser compatibility
The HTML noscript tag is supported by different types of browsers.
- Chrome
- Firefox
- Opera
- Safari
- Internet Explorer
Example:
<!DOCTYPE html> <html> <body> <script> document.write("Hello World!") </script> <noscript>Your browser does not support JavaScript!</noscript> </body> </html>
Output:
Hello World!