Chrome remembers scroll position Chrome remembers scroll position google-chrome google-chrome

Chrome remembers scroll position


In Chrome 46+, the auto scroll behavior can be turned off using history.scrollRestoration:

if ('scrollRestoration' in history) {  history.scrollRestoration = 'manual';}

source: https://developers.google.com/web/updates/2015/09/history-api-scroll-restoration


I've checked on chrome, it worked well. Sometimes setTimeout does trick :)

<script type="text/javascript">window.onload=function(){    setTimeout(function(){        scrollTo(0,-1);    },0);}</script>


x = 0;  //horizontal coordy = document.height; //vertical coordwindow.scroll(x,y);

Some Javascript like that may very well be able to be manipulated to stop the auto scrolling.

It depends though, are you happy for the scroll to be simply set to automatically go to the top, or are you actually looking for the Chrome standard option to take the page to last scroll position, to be turned off completely?

What are you currently attempting to use for scrollTop()?