jsdom breaking changes
Updated December 4, 2026
On this page
Latest version 31.0.1, released November 13, 2026. Source repository
Its 30.0.0 release requires Node.js 22.22.2 or later. Node.js end of life dates.
- From 30.1.3 to 31.0.1: 12 breaking changes in 2 versions.
- From 20.0.0 to 31.0.1: 80 breaking changes in 19 versions.
jsdom 31.0.1 breaking changes
- Behavior changed
element.tabIndex
Invalid and out-of-range tabindex values now return the element's default instead of zero or wrapping, and values with trailing non-digits use their leading integer. Code that relied on the old values, such as tabindex="1e2" returning 100... github.com
jsdom 31.0.0 breaking changes
- Behavior changed
Fonts, antialiasing, and encoded bytes can differ from before. PNG, JPEG, and WebP serialization is supported, and other MIME types fall back to PNG. github.com - Behavior changed
CSS parsing, selector matching and computed styles now use a new integrated implementation. CSS serialization and computed values can differ from previous releases. github.com - Behavior changed
document
The page-completion load event now fires only on the window. Code listening for load on the document must switch to window.addEventListener("load", ...) or window.onload. github.com - Behavior changed
document.close
Script-created input streams now remain open until document.close() is called. Code that depended on the stream closing earlier must call document.close(). github.com - Behavior changed
document.open
document.open, including implicit calls from document.write, now clears event listeners and handlers on the document, its descendants and its window. Re-register any listeners after reopening. github.com - Behavior changed
JSDOM
Parsing pauses at blocking scripts, so the JSDOM constructor can return a partially parsed document. Wait for DOMContentLoaded or the window load event, checking document.readyState first. github.com - Behavior changed
JSDOM.fromFile
Parsing pauses at blocking scripts, so JSDOM.fromFile can return a partially parsed document. Wait for DOMContentLoaded or the window load event, checking document.readyState first. github.com - Behavior changed
JSDOM.fromURL
Parsing pauses at blocking scripts, so JSDOM.fromURL can return a partially parsed document. Wait for DOMContentLoaded or the window load event, checking document.readyState first. github.com - Configuration changed
The optional canvas and image decoding backend is now @napi-rs/canvas. Install @napi-rs/canvas v1.0.13 or later alongside jsdom, since installing canvas alone no longer enables this support. Rendering and encoded image bytes can differ. github.com - Configuration changed
The latest versions of jsdom need newer Node.js versions. Check the engines field in package.json for the supported range. github.com
And 1 more in this version. Sign up to see every change
jsdom 30.1.3 breaking changes
- Behavior changed
XMLHttpRequest
After a cross-origin redirect, XMLHttpRequest no longer sends credentials supplied to xhr.open(), including in response to authentication challenges from the destination. Code relying on that reuse must supply credentials again. github.com
jsdom 30.1.1 breaking changes
- Behavior changed
element.innerHTML
Setting innerHTML on an element in an XML document now throws when an attribute value contains invalid characters, where it previously did not. Check code that writes untrusted markup into XML documents. github.com - Behavior changed
element.outerHTML
Reading outerHTML on an element in an XML document now throws when an attribute value contains invalid characters, where it previously did not. Check code that serializes XML documents with invalid attribute data. github.com
jsdom 30.1.0 breaking changes
- Behavior changed
window.close
Calling window.close() now preserves access to the document and its DOM through retained references. Code that relied on the previous teardown behavior should be checked. github.com
jsdom 30.0.0 breaking changes
- Behavior changed
jsdom 30 requires Node.js ^22.22.2, ^24.15.0 or >=26.0.0. Users on older Node.js versions must upgrade before installing. github.com
Older versions
14 older versions, each with its first changes. Sign up to see every change
Show 14 older versions
jsdom 29.0.2 breaking changes
- Behavior changed
getComputedStyle
getComputedStyle() now applies computed value rules across a broader set of properties, so returned values can differ from earlier versions. Code that compares or parses computed styles should be checked. github.com
jsdom 29.0.0 breaking changes
- Removed
The minimum supported Node.js v22 version is now v22.13.0. Users on v22.12.0 must upgrade Node.js before using this release. github.com - Behavior changed
Fetches to ports listed as bad in the fetch specification are now blocked. Code that fetches from such ports will fail and must use a different port. github.com
And 4 more in this version.
jsdom 28.0.0 breaking changes
- Removed
"jsdom"
"jsdom" was removed in jsdom 28.0.0 npmjs.com - Removed
FinalizationRegistryConstructor
FinalizationRegistryConstructor was removed in jsdom 28.0.0 npmjs.com
And 18 more in this version.
jsdom 27.4.0 breaking changes
- Behavior changed
XML documents are now decoded as UTF-8 more often instead of sniffing for a meta charset or using the parent frame's encoding. Code that relied on the old encoding detection may see different text. github.com
jsdom 27.0.1 breaking changes
- Behavior changed
The minimum Node.js version rose from v20.0.0 to v20.19.0, v22.12.0 and v24.0.0. Users on earlier Node.js versions should stay on jsdom v26.1.0. github.com
jsdom 27.0.0 breaking changes
- Removed
The minimum supported Node.js version is now v20. Run jsdom on Node.js 20 or later. github.com - Removed
omitJSDOMErrors
Use the jsdomErrors option of forwardTo() to control which errors reach the Node.js console; omitJSDOMErrors is gone. github.com
And 7 more in this version.
jsdom 26.0.0 breaking changes
- Removed
The optional canvas peer dependency must now be version 3 instead of version 2. Users of canvas v2 must upgrade canvas. github.com
jsdom 25.0.0 breaking changes
- Behavior changed
EventTarget.prototype
When runScripts is set to "dangerously" or "outside-only", EventTarget.prototype now inherits from the Object.prototype inside jsdom rather than the Node.js one. Code relying on instanceof checks across realms may behave differently. github.com
jsdom 24.1.2 breaking changes
- Behavior changed
blur
Calling blur() no longer fires focus and focusin events on the Document, and blur and focusout events no longer have relatedTarget set. Code that relies on these events or properties must change. github.com
jsdom 24.0.0 breaking changes
- Removed
:has
The release switches the selector engine back to nwsapi, which drops support for the :has() pseudo-class. Code that relies on :has() in querySelector or similar calls must be rewritten. github.com
jsdom 23.0.0 breaking changes
- Removed
Node.js v18 is now the minimum supported version, so users on older Node.js releases must upgrade before installing this version. github.com
jsdom 22.0.0 breaking changes
- Removed
jsdom is no longer supported as a browserified bundle for running in the browser, so code relying on that bundle must change. github.com - Removed
Node.js v16 is now the minimum supported version, so older Node.js releases are no longer supported. github.com
jsdom 21.0.0 breaking changes
- Behavior changed
Window.document
These Window properties can no longer be redefined or deleted. Code that tried to redefine them must be changed. github.com - Behavior changed
Window.external
Assigning to these Window properties now overrides their value instead of being silently ignored. github.com
And 16 more in this version.
jsdom 20.0.0 breaking changes
- Removed
jsdom 20 requires Node.js 14 or later. Users on older Node.js versions must upgrade before installing. github.com
Check your code
These are the changes. To see which of them reach your code, scan a public repository, or have your coding agent call check_code with your manifest or lockfile over MCP. The API reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

Put your code on continuous maintenance.
Scan a public repository now, or give your agent one line.
See how out of date your code is.
Tell your agent what changed since it was trained.
claude mcp add --transport http since https://api.since.dev/mcpCodex, Cursor and any MCP client use https://api.since.dev/mcp.