# @lwc/engine-dom

> Renders LWC components in a DOM environment.

Latest version **9.4.3** (published 2026-09-02) · MIT license · 0 weekly downloads

## Install

```sh
npm install @lwc/engine-dom
pnpm add @lwc/engine-dom
yarn add @lwc/engine-dom
bun add @lwc/engine-dom
```

## Health

**Score 70/100 (B)** — status: active.

Positive: has types; esm support; no vulnerabilities; has provenance; recently updated; high maintenance score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 9.4.3 |
| Published | 2026-09-02 |
| First published | 2020-06-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=16.6.0 |
| Dependencies | 0 |
| Unpacked size | 904 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 1787 |
| Maintainers | lwc-admin, caridy, jye-sf, ravi.jayaramappa, jodarove, abdulsattar, rax-it1, lpomerleau |
| Keywords | lwc |

## Links

- npm: https://www.npmjs.com/package/@lwc/engine-dom
- Repository: https://github.com/salesforce/lwc
- Homepage: https://lwc.dev
- Issues: https://github.com/salesforce/lwc/issues
- npm.io page: https://npm.io/package/@lwc/engine-dom

## Recent versions

- 9.4.3 (latest) — 2026-09-02
- 9.3.10 (winter27) — 2026-09-21
- 9.4.6-alpha.0 (canary) — 2026-09-11
- 9.1.5 (summer26) — 2026-04-28
- 8.25.1 (spring26) — 2025-11-19
- 8.20.6 (winter26) — 2025-10-20
- 8.16.5 (summer25) — 2025-05-05
- 8.10.3 (spring25) — 2025-01-09
- 7.1.5 (winter25) — 2024-10-10
- 7.0.1-alpha.0 (next) — 2024-06-21
- 6.4.5 (summer24) — 2024-06-05
- 5.0.10 (spring24) — 2024-03-20
- 3.0.4 (winter24) — 2023-10-02
- 2.40.2-lbc (lbc-avante-garde) — 2023-03-21
- 2.31.8 (spring23) — 2023-03-20
- … 458 more at https://npm.io/package/@lwc/engine-dom/versions

## README

# @lwc/engine-dom

This package can be used to render LWC components as DOM elements in a DOM environment.

## Supported APIs

This package supports the following APIs.

### createElement()

This function creates an LWC component, given a tag name and an LWC constructor.

```js
import { createElement } from 'lwc';
import LightningHello from 'lightning/hello';

const element = createElement('lightning-hello', { is: LightningHello });

document.body.appendChild(element);
```

## Experimental APIs

Experimental APIs are subject to change, may be removed at any time, and should be used at your
own risk!

### getComponentConstructor()

This experimental API provides access to the component constructor, given an `HTMLElement`.

### isNodeFromTemplate()

This experimental API enables the detection of whether a node was rendered from an LWC template.

## Deprecated APIs

### buildCustomElementConstructor() (deprecated as of v1.3.11)

This function can build a Web Component class that can be registered as a new element via
`customElements.define()`, given an LWC constructor.

Deprecated in favor of using the `CustomElementConstructor` property of an LWC constructor.

```js
import { LightningElement } from 'lwc';

class LightningHello extends LightningElement {}

// Don't do this.
customElements.define('lightning-hello', buildCustomElementConstructor(LightningHello));

// Do this instead.
customElements.define('lightning-hello', LightningHello.CustomElementConstructor);
```

---
_Source: https://npm.io/package/@lwc/engine-dom · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
