Change url without a page refresh


I wanted the url to change but there to be no redirect/refresh of the page. I was able to do this by a little js.

history.pushState('data', '', 'http://' + window.location.host + '/month/' + month );