JavaScriptMedium
How do you detect if JavaScript is disabled on a page?
By FrontendPro Editorial Team Updated 8/8/2026
#JavaScript
Answer
To detect if JavaScript is disabled on a page, you can use the <noscript> HTML tag. This tag allows you to display content or messages to users who have JavaScript disabled in their browsers. For example, you can include a message within the <noscript> tag to inform users that JavaScript is required for the full functionality of the page.
html
<noscript>
<p>
JavaScript is disabled in your browser. Please enable JavaScript for the
best experience.
</p>
</noscript>
