Articles → HTML → Head tag in HTML

Head tag in HTML






Purpose of head tag















Syntax


<head>
…
</head>



Example


<html>
<head>
    <title>head section demo</title>
    <meta charset="UTF-8">
    <script src="source_of_js_file">
        // We can define scripts here
    </script>
    <style type="text/css">
        /*Define styles*/
    </style>
    <link href="style_file_link" rel="stylesheet" />
</head>
<body>
</body>
</html>





Browser support


Internet ExplorerFirefoxChromeSafariOperaEdge
YesYesYesYesYesYes



Posted By  -  Karan Gupta
 
Posted On  -  Tuesday, September 27, 2016
 
Updated On  -  Wednesday, March 08, 2017

Query/Feedback


Your Email Id  
 
Subject 
 
Query/FeedbackCharacters remaining 250