# Is ember-data ESM-only? Can you require() it?

> ember-data@5.9.1 is ESM-only. ESM-only since 5.3.4 — last CommonJS version is 5.3.3.

(Legacy) The lightweight reactive data library for Ember applications

Last verified Sep 9, 2026 against ember-data@5.9.1.

ember-data dropped its CommonJS build in 5.3.4 (June 2024). The last version with a plain require()-able CommonJS entry is 5.3.3, published Mar 2, 2024; it declares support for Node.js >= 18.19.1.

require("ember-data") failed in our probe on Node.js 20+ as well; see the runtime table for the error before relying on it. On Node.js 18, which has no require(esm), require("ember-data") fails with ERR_REQUIRE_ESM.

## What to do

1. require("ember-data") failed in our probe on Node.js 20+ as well; see the runtime table for the error before relying on it.
2. From a CommonJS file, use a dynamic import inside an async function: const emberData = await import("ember-data"). That works on every Node.js version the package supports.
3. If you need a synchronous require() or run Node.js 18: npm install ember-data@5.3.3, the last CommonJS release (published Mar 2, 2024); it declares Node.js >= 18.19.1.
4. TypeScript: types are bundled; install nothing extra.

## Facts

- Latest: 5.9.1 (Sep 5, 2026)
- Module format: ESM-only
- Last CommonJS version: 5.3.3
- ESM-only since: 5.3.4 (Jun 15, 2024)
- TypeScript types: bundled
- Node engines: not declared
- Weekly downloads: 134K
- License: MIT

## Runtime test results for ember-data@5.9.1

Installed and executed on Sep 9, 2026 with require("ember-data") from a CommonJS file and import "ember-data" from an ES module.

| Runtime | require("ember-data") | import "ember-data" |
|---|---|---|
| Node.js 18 | fails (SyntaxError) | fails (SyntaxError) |
| Node.js 20 | fails (ERR_MODULE_NOT_FOUND) | fails (ERR_MODULE_NOT_FOUND) |
| Node.js 22 | fails (ERR_MODULE_NOT_FOUND) | fails (ERR_MODULE_NOT_FOUND) |
| Node.js 24 | fails (ERR_MODULE_NOT_FOUND) | fails (ERR_MODULE_NOT_FOUND) |
| Node.js 26 | fails (ERR_MODULE_NOT_FOUND) | fails (ERR_MODULE_NOT_FOUND) |
| Bun 1.4.0 | fails (Error) | fails (Error) |

## How to import ember-data

ES modules:

```js
import * as emberData from "ember-data";
```

Namespace import shown because the ESM entry may have no default export; use named imports for what it exports.

CommonJS:

```js
// require("ember-data") failed in our probe on Node.js 20.19+, 22.12+ and newer as well (ERR_MODULE_NOT_FOUND); see the runtime table.

// Any Node.js version the package supports, from an async function:
async function main() {
  const emberData = await import("ember-data");
}

// Or pin the last CommonJS release (declares Node.js >= 18.19.1):
// npm install ember-data@5.3.3
```

## Module format by version

Derived from the type, main and exports fields of every stable release on npm (257 versions; the newest 60 shown).

| Versions | Format | First published |
|---|---|---|
| 5.3.4 – 5.9.1 | ESM-only | Jun 15, 2024 |
| 4.6.5 – 5.3.3 | CommonJS | May 8, 2024 |

## Frequently asked

**Is ember-data ESM-only?**

ember-data@5.9.1 is ESM-only. ember-data dropped its CommonJS build in 5.3.4 (June 2024). The last version with a plain require()-able CommonJS entry is 5.3.3, published Mar 2, 2024; it declares support for Node.js >= 18.19.1.

**Which version of ember-data still supports CommonJS / require()?**

5.3.3 is the last version of ember-data with a CommonJS build; it declares Node.js >= 18.19.1. Install it with "npm install ember-data@5.3.3". Every version from 5.3.4 on is ESM-only.

**How do I use ember-data from a CommonJS file?**

From a CommonJS file, use a dynamic import inside an async function: const emberData = await import("ember-data"). That works on every Node.js version the package supports. require("ember-data") failed in our probe on Node.js 20+ as well; see the runtime table for the error before relying on it. Alternatively pin ember-data@5.3.3 (declares Node.js >= 18.19.1).

**Does ember-data work in Bun?**

Importing ember-data failed in Bun 1.4.0 on Sep 9, 2026: error: Cannot find module '@ember/debug' from '/Users/boat/Projects/top-seo/data/probe-work/ember-data/node_modules/ember-data/dist/index.js'

**Does ember-data ship TypeScript types?**

Yes. ember-data bundles its own type declarations; no @types package is needed.

## Links

- [ember-data on npm](https://www.npmjs.com/package/ember-data)
- [Source repository](https://github.com:warp-drive-data/warp-drive)
- [HTML version](https://canirequire.com/package/ember-data/)
- [JSON version](https://canirequire.com/package/ember-data.json)

---

For scripts and AI agents: any package is at https://canirequire.com/package/<name>/index.md (Markdown) or https://canirequire.com/package/<name>.json (JSON); the site index is https://canirequire.com/llms.txt. Fetch the URL directly; no search needed.
