scroll up 10px js code example Example: scroll through page with javascript window.scroll({ top: 0, left: 0, behavior: 'smooth' });