1<button><a href='https://google.com' alt='Broken Link'>This is a button</a></button>
1<!-- if you are on Window : -->
2<button onclick="window.location.href='page2.html'">
3 Button
4</button>
5
6<!-- if you are on linux or macOS : -->
7<button onclick="location.href='page2.html'">
8 Button
9</button>
1<!DOCTYPE html>
2<html>
3 <head>
4 <title>Title of the document</title>
5 </head>
6 <body>
7 <form>
8 <input type="button" onclick="window.location.href = 'https://www.w3docs.com';" value="w3docs"/>
9 </form>
10 </body>
11</html>
1<button onclick="location.href='http://www.example.com'" type="button">
2 www.example.com</button>
1<input type="button" onclick="location.href='https://google.com';" value="Go to Google" />
2