happy-dom
npmv20.14.0TypeScriptHappy DOM is a JavaScript implementation of a web browser without its graphical user interface. It includes many web standards from WHATWG DOM and HTML.
Safe to adopt
Yes — happy-dom scores well across adoption, maintenance, weight, supply chain, and licensing. No download data reported for this package yet. Last published 6 days ago. 50 releases in the last 2 years.
- ?Adoption: grade ?, Not reported by this registry.
No download data reported for this package yet.
- AMaintenance: grade A, Excellent.
Last published 6 days ago. 50 releases in the last 2 years.
- BWeight: grade B, Good.
Pulls in 8 transitive packages, about 11 MB installed (at least — some of the tree is still being crawled).
- BSupply chain: grade B, Good.
This package has a single maintainer (bus factor of 1).
- ALicense: grade A, Excellent.
MIT — permissive, with no copyleft found in the dependency tree.
Grades are computed deterministically from registry metadata collected by PackageGraph — downloads, dependents, publish dates, the resolved dependency tree, maintainer count, and declared licenses. No third-party scores are used.
Install cost
What you actually take on by adding happy-dom to a project.
Runtime packages this one declares itself.
Distinct packages in the full runtime tree, deduplicated the way a package manager would.
Unpacked size of this package plus its entire runtime tree.
Longest resolved dependency chain below this package.
Part of this dependency tree has not been crawled yet, so these figures are a lower bound rather than a final total.
Licenses in the dependency tree
Every license you inherit by installing happy-dom, not just its own. Check this before a legal review, not after.
Compatibility
- Node.js
- node >=20.0.0
- Module format
- ESM only
- TypeScript
- Types included
- Install scripts
- None
happy-dom vs the alternatives
Packages solving a similar problem in the npm ecosystem, compared on the signals that drive an adoption decision.
| Package | Weekly downloads | Dependents | License | Last release |
|---|---|---|---|---|
| happy-domthis page | 0 | 6 | MIT | 6 days ago |
| jsdom | 0 | 20 | MIT | 1 day ago |
| ssri | 0 | 2 | ISC | 1 day ago |
| @testing-library/jest-dom | 56M | 6 | MIT | 1 day ago |
| default-browser | 52.6M | 1 | MIT | 1 day ago |
| cross-fetch | 32.9M | 2 | MIT | 1 day ago |
Dependencies
Declared by happy-dom v20.14.0. Runtime dependencies are installed with the package; dev dependencies are not.
Runtime (7)
Dev (7)
Used by
Popular packages that depend on happy-dom.
Next generation testing framework powered by Vite
Minimal H(TTP) framework built for high performance and portability.
Low-level network interception library for Node.js.
SQLite Wasm conveniently wrapped as an ES Module.
WhatWG/W3C compliant EventSource client for Node.js and browsers
Module resolution utilities based on Node.js upstream implementation.
Relationship graph
Dependencies (left) and dependents (right) of happy-dom.
Frequently installed together
TypeScript definitions for node
Next generation testing framework powered by Vite
Native-ESM powered web dev build tool
Cross-platform WebSocket Servers for Node.js, Deno, Bun and Cloudflare Workers
V8 coverage provider for Vitest
Fast, unopinionated, minimalist web framework
Browser running for Vitest using playwright
A JavaScript implementation of many web standards
Modify strings, generate sourcemaps
Web framework built on Web Standards
Composable caching primitives with TTL, SWR, and HTTP response caching
A high-level API to automate web browsers
Release history
50 releases in the last two years, typically about 0 days apart.
| Version | Published | Size | License |
|---|---|---|---|
| 20.14.0latest | 6 days ago | 8.2 MB | MIT |
| 20.13.2 | 7 days ago | 8.2 MB | MIT |
| 20.13.1 | 7 days ago | 8.2 MB | MIT |
| 20.13.0 | 7 days ago | 8.2 MB | MIT |
| 20.12.2 | 8 days ago | 8.2 MB | MIT |
| 20.12.1 | 8 days ago | 8.2 MB | MIT |
| 20.12.0 | 11 days ago | 8.3 MB | MIT |
| 20.11.15 | 12 days ago | 8.2 MB | MIT |
| 20.11.14 | 12 days ago | 8.2 MB | MIT |
| 20.11.13 | 12 days ago | 8.2 MB | MIT |
| 20.11.12 | 13 days ago | 8.2 MB | MIT |
| 20.11.11 | 13 days ago | 8.2 MB | MIT |
| 20.11.10 | 13 days ago | 8.2 MB | MIT |
| 20.11.9 | 13 days ago | 8.2 MB | MIT |
| 20.11.8 | 14 days ago | 8.2 MB | MIT |
Overview
happy-dom is an npm package that happy DOM is a JavaScript implementation of a web browser without its graphical user interface. It includes many web standards from WHATWG DOM and HTML. It has 6 known dependents in the graph. The latest version is 20.14.0, released under the MIT license.
Who should use it
Teams working in the npm ecosystem who need happy DOM is a JavaScript implementation of a web browser without its graphical user interface. It includes many web standards from WHATWG DOM and HTML and value a focused solution.
When not to use it
Consider an alternative if you need to or if a more actively-maintained option better fits your npm stack.
Pros
- Ships TypeScript type definitions.
- Clear open-source license (MIT).
Cons
- No significant drawbacks detected from available metadata.
Auto-generated from collected registry metadata. No external claims are inferred.
Maintainers
Frequently asked questions
Should I use happy-dom?
Yes — happy-dom scores well across adoption, maintenance, weight, supply chain, and licensing. No download data reported for this package yet. Last published 6 days ago. 50 releases in the last 2 years.
How do I install happy-dom?
Run `npm install happy-dom` to add happy-dom to your npm project.
How many dependencies does happy-dom have?
happy-dom declares 14 direct dependencies and pulls in 8 packages in total once its runtime tree is resolved totalling about 11 MB on disk.
What license is happy-dom released under?
happy-dom is distributed under the MIT license. Its dependency tree also includes: BSD-2-Clause, MIT.
How popular is happy-dom?
npm does not publish download counts. Within PackageGraph's crawl, 6 known packages depend on happy-dom.
Is happy-dom still maintained?
The most recent release of happy-dom (v20.14.0) was published 6 days ago.
Does happy-dom run install scripts?
No. happy-dom does not define preinstall, install, or postinstall scripts, so installing it does not execute publisher-supplied code.