go to another html page in javascript code example Example: go to another html page in javascript window.location.href = "http://mywebsite.com/home.html";