# @ipld/dag-json

> JS implementation of DAG-JSON

Latest version **11.0.1** (published 2026-07-30) · Apache-2.0 OR MIT license · 0 weekly downloads

## Install

```sh
npm install @ipld/dag-json
pnpm add @ipld/dag-json
yarn add @ipld/dag-json
bun add @ipld/dag-json
```

## Health

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

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

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 11.0.1 |
| Published | 2026-07-30 |
| First published | 2019-05-04 |
| Weekly downloads | 0 |
| License | Apache-2.0 OR MIT |
| TypeScript types | bundled |
| Module format | ESM |
| Dependencies | 2 |
| Unpacked size | 309.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| Author | Rod |
| Maintainers | daviddias, mikeal, vmx, alanshaw, achingbrain, vascosantos, rvagg, lidel, npm-service-account-ipld |
| Keywords | ipfs, ipld, multiformats |

## Links

- npm: https://www.npmjs.com/package/@ipld/dag-json
- Repository: https://github.com/ipld/js-dag-json
- Homepage: https://github.com/ipld/js-dag-json#readme
- Issues: https://github.com/ipld/js-dag-json/issues
- npm.io page: https://npm.io/package/@ipld/dag-json

## Dependencies (2)

- [cborg](https://npm.io/package/cborg.md) ^6.1.1
- [multiformats](https://npm.io/package/multiformats.md) ^14.0.0

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 11.0.1 (latest) — 2026-07-30
- 11.0.0 — 2026-05-12
- 10.2.9 — 2026-05-12
- 10.2.8 — 2026-05-12
- 10.2.7 — 2026-04-02
- 10.2.6 — 2026-01-19
- 10.2.5 — 2025-05-22
- 10.2.4 — 2025-05-08
- 10.2.3 — 2024-10-29
- 10.2.2 — 2024-06-24
- 10.2.1 — 2024-06-01
- 10.2.0 — 2024-02-16
- 10.1.7 — 2024-01-10
- 10.1.6 — 2023-12-30
- 10.1.5 — 2023-10-03
- … 68 more at https://npm.io/package/@ipld/dag-json/versions

## README

# @ipld/dag-json

[![codecov](https://img.shields.io/codecov/c/github/ipld/js-dag-json.svg?style=flat-square)](https://codecov.io/gh/ipld/js-dag-json)
[![CI](https://img.shields.io/github/actions/workflow/status/ipld/js-dag-json/js-test-and-release.yml?branch=master\&style=flat-square)](https://github.com/ipld/js-dag-json/actions/workflows/js-test-and-release.yml?query=branch%3Amaster)

> JS implementation of DAG-JSON

# Install

```console
$ npm i @ipld/dag-json
```

## Browser `<script>` tag

Loading this module through a script tag will make its exports available as `IpldDagJson` in the global namespace.

```html
<script src="https://unpkg.com/@ipld/dag-json/dist/index.min.js"></script>
```

# Usage

`@ipld/dag-json` is designed to be used within multiformats but can be used separately. `encode()`, `decode()` are available as exports, as are `name` and `code` to match with the corresponding DAG-JSON [multicodec](https://github.com/multiformats/multicodec/).

# API Docs

- <https://ipld.github.io/js-dag-json>

# License

Licensed under either of

- Apache 2.0, ([LICENSE-APACHE](https://github.com/ipld/js-dag-json/LICENSE-APACHE) / <http://www.apache.org/licenses/LICENSE-2.0>)
- MIT ([LICENSE-MIT](https://github.com/ipld/js-dag-json/LICENSE-MIT) / <http://opensource.org/licenses/MIT>)

# Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

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