scrolltop id code example Example: jquery keep scroll position var scroll = $(window).scrollTop(); // yada $("html").scrollTop(scroll);