<html>
<body>
<h1>The Window Location Object</h1>
<h2>The host Property</h2>
<p id="demo"></p>
<script>
let host = location.host;
document.getElementById("demo").innerHTML = host;
</script>
</body>
<!-- /jsref/tryit.asp?filename=tryjsref_loc_host
</html>