Javascript: <noscript> Tag

The <noscript> tag is used to provide an alternate content for users that have disabled scripts in their browser or have a browser that doesn't support client-side scripting. In these cases, the content inside the <noscript> element will be displayed.

HTML file: Displayed by browser:
<!DOCTYPE html>
  <html>
    <body>

<p id="demo"></p>

<script>
document.getElementById("demo").innerHTML = "Hello JavaScript!";
</script>

<noscript>Sorry, your browser does not support JavaScript!</noscript>

<p>A browser without support for JavaScript will show the text written inside the noscript element.</p>

   </body>
  </html>

A browser without support for JavaScript will show the text written inside the noscript element.

The <noscript> element can contain any elements that you use in the <body> element of a normal HTML page.

Back button Table of Contents Next button