how to redirect to new tab in html using javascript code example Example: js redirect to url new tab window.open('http://stackoverflow.com', '_blank');