When changing HTML content inside JEditorPane, the scroll bar always goes down to the end - if you want to show the start of new page neither scrollTo(Anchor), nor getVerticalScrollBar().setValue(0) will work. However, moveCaretPosition(0) will do the job.