Change URL and enable browser back button with AJAX

We all are aware that clicking any link that sends AJAX call doesn't change the url with the href of the link clicked. As the browsers history is not also updated, back button too will not work. One alternative is to use PJAX that updates the url and browsers history thus enabling back button. What if we don't what to use PJAX? There is way of manipulate browsers history to reflect updated url and enable back button. This technique is used by Github in its file browser. When we click on folder in Github repo, the page updates via AJAX