<label for="planet">Which planet were you born on?</label>
<input id="planet" type="text" value="Azarath" />HTMLInputElement: defaultValue property / notebook
HTMLInputElement: defaultValue property
Runnable notebook: every JavaScript, HTML and CSS example on this page executes in a sandboxed local frame. Nothing leaves the browser.
const inputElement = document.querySelector("#planet");
console.log(`Original value: ${inputElement.defaultValue}`); // "Original value: Azarath"