title: How to remove the hash from window.location (URL) with JavaScript without page refresh?
body: <p>I have URL like: <code>http://example.com#something</code>, how do I remove <code>#something</code>, without causing the page to refresh?  </p>
  
  <p>I attempted the following solution:</p>
  
  <pre><code>window.location.hash = '';
  </code></pre>
  
  <p><strong>However, this doesn't remove the hash symbol <code>#</code> from the URL.</strong></p>