A button that will show the HTML source of the page like the "View Source" option in the browser's menu <input type="button" value="View Source"…