Back button

Marko Krstić
8 Dec 2019
function goBack() {
  window.history.back();
}
<button onclick="goBack()">Go Back</button>

This code will lead you to the page same as you pressed back in Browser

Was this article helpful?

Tags

Categories

Never miss new post again

Subscribe and get list of new posts in your inbox

Click to Copy