MDN self-hosted library · e01.org

Node: baseURI property

Runnable notebook: every JavaScript, HTML and CSS example on this page executes in a sandboxed local frame. Nothing leaves the browser.

html
<output>Not calculated</output>
js
const output = document.querySelector("output");
output.value = output.baseURI;
html
<base href="https://developer.mozilla.org/modified_base_uri/" />
<output>Not calculated</output>
js
const output = document.querySelector("output");
output.value = output.baseURI;