Elestia Open Source Ratings
7.1

Acorn

A strong pick. 4th of 9 JavaScript parsers and codemods.

Acorn is a small, spec-accurate JavaScript parser written in JavaScript. It produces the standard ESTree tree and has no dependencies. It is still a solid pick for parsing plain JavaScript in pure JS. It cannot parse TypeScript without a plugin, it cannot print code back out, and Oxc and Babel now cover more of this category's job.

Best for: Tool authors who need a light, dependency-free ESTree parser for plain JavaScript that runs anywhere JS runs.

GitHubnpm

Scores

Overall7.1

How strongly do we recommend it for a new project today?

Claude Opus 5.5: 6.5, likely 5.5 to 7.5

Acorn is a trusted, dependency-free and stable parser for plain JavaScript. For that narrow job it is still a good choice. For a new project in this category, the lack of TypeScript and of any code printing or transforms counts heavily against it. Oxc is faster and covers TypeScript, and Babel covers TypeScript and JSX. Its download growth is below the median, which shows the field moving away from it.

GPT-6.2 Sol: 7.6, likely 6.5 to 8.6

Acorn is a strong pick for new tools that need fast, portable ESTree parsing of standard JavaScript. Babel parser and Oxc cover TypeScript and JSX in a single parser package, and Recast is a better fit when preserving formatting is central to the job. The recent release cadence and continued use by ESLint support the recommendation, while slower relative download growth and major bundlers moving away limit confidence in its future share.

Needed by many4.4

How many developers need a tool for this job?

Claude Opus 5.5: 4.5, likely 3.0 to 6.0

Most developers use a parser only indirectly, through their build tools. Writing parser code directly is a task for tool and plugin authors. Acorn also covers only plain JavaScript and does no code changes, so it is narrower than this category, which includes TypeScript and codemods.

GPT-6.2 Sol: 4.3, likely 3.2 to 5.5

Acorn serves developers building linters, bundlers, editors, and code analyzers across runtimes. Build steps are common among State of JavaScript respondents, but the survey leaves the share of developers who select a parser directly unmeasured. Acorn's JavaScript focus further narrows its audience among teams working with TypeScript or JSX.

Helps a lot7.2

How well does it do the job for those who need it?

Claude Opus 5.5: 6.5, likely 5.5 to 7.5

For plain JavaScript it is correct, small and fast for a parser written in JS. It ships types, a walker and an error-tolerant parser. But it parses no TypeScript and prints no code. Oxc is several times faster, and Oxc and Babel both handle TypeScript and JSX without extra packages, so most new work today is better served elsewhere.

GPT-6.2 Sol: 7.8, likely 6.7 to 8.8

Acorn 8.19.0 offers a small, well-documented API, typed ESTree nodes, and precise syntax errors. A benchmark from the Yuku team put it ahead of Babel and Oxc on two JavaScript inputs, while a user reported a JavaScriptCore slowdown, so speed depends on the workload and runtime. The API examples give coding agents a clear starting point, though agent accuracy is unmeasured. Babel covers TypeScript and JSX through bundled plugins, and Recast adds formatting-preserving output.

Holds up over time7.2

Will it still be a good choice in two years?

Claude Opus 5.5: 7.0, likely 5.5 to 8.0

It is maintained and stable. There were 49 commits and 4 npm releases in the last year, only 15 issues are open, and 8.x has had no breaking changes in years. One long-time maintainer does most of the work and there is no visible funding. Some tools are moving away from it: Rollup now uses SWC, and Vite now uses Rolldown and Oxc. webpack, ESLint and Svelte still keep it in wide use.

  • github commitsLastYear: 49 commits
  • npm versionsLastYear: 4 releases, latest 8.19.0 in October 2026
  • github openIssues: 15 open against 877 closed
  • Rollup 4 switched to an SWC-based parser; Vite moved to Rolldown/Oxc: Some tools are moving away from it

GPT-6.2 Sol: 7.4, likely 6.2 to 8.5

Four npm releases and 49 repository commits in the past year show steady upkeep, with recent syntax fixes shipping within the 8.x series. Two maintainers answered an October performance report the same day, and a patch followed four days later. Webpack recently switched to its own parser, and Rollup had already moved away. Those departures and limited visibility into Acorn-specific funding and typical review times widen the range.

Used widely7.4

How many use it, and is that growing?

Claude Opus 5.5: 7.5, likely 6.5 to 8.5

It has 1.35B downloads in 4 weeks and 1.1M dependent repos, but most of that comes through webpack, espree and other tools rather than direct choice. The 8,880 dependent packages show real direct use. Downloads grew 2.65x in a year, below the 4.1x median, while Oxc and Meriyah grew much faster. Acorn is losing share among new projects.

  • npm downloadsLast4Weeks: 1.35B, up from 509M a year ago (ratio 2.65)
  • medianDownloadsRatio: The median is 4.1, so Acorn is losing ground
  • dependents: 1.12M repos and 8,880 packages
  • peers Oxc parser: Grew from 5M to 403M downloads in a year

GPT-6.2 Sol: 7.2, likely 5.9 to 8.5

Ecosyste.ms found 1.12 million dependent repositories and 8,880 packages, fewer repositories than Babel parser or Esprima and more than Recast. Downloads rose from 509 million to 1.35 billion in four weeks, a 2.65× ratio that trails the 4.1× baseline and Babel parser's 3.84×. ESLint's Espree helps drive transitive installs, and the stars and two Bluesky posts cover the whole Acorn repository. The installed base is large, while the share attributable to deliberate new choices remains hard to estimate.

  • evidence.dependents, peers: Large indexed dependent base, behind Babel parser and Esprima by repository count
  • evidence.npm.downloadsLast4Weeks, evidence.npm.downloadsSame4WeeksYearAgo, medianDownloadsRatio, peers: 2.65× year over year against a 4.1× catalog baseline
  • evidence.github.stars, evidence.bluesky.posts, peers: 11,479 repository stars and two Bluesky posts, versus Babel's 18 posts
  • github.com/eslint/js/blob/main/packages/espree/package.json: Espree installs Acorn directly
  • github.com/acornjs/acorn: Repository also contains the walker and loose parser
Vouched for8.0

Who stands behind it being good?

Claude Opus 5.5: 8.0, likely 7.0 to 9.0

Major tools build on it and use it in production every day. ESLint's default parser, espree, is an adapter over Acorn, and webpack and Svelte also rely on it. Oxc treats Acorn's output as its reference and counts any difference as a bug. Surveys and public user discussion of it are sparse.

GPT-6.2 Sol: 8.0, likely 7.0 to 9.0

ESLint's Espree builds on Acorn, and MDX relies on it for JavaScript expressions and module syntax. Recast documents Acorn as a supported parser, and the Yuku team's benchmark shows competitive JavaScript parsing speed on its test machine. Acorn-specific satisfaction data is sparse, and webpack's recent move to its own parser reduces the weight of its past adoption.

Safe7.6

How safe is it to depend on?

Claude Opus 5.5: 8.0, likely 7.0 to 9.0

It has zero runtime dependencies and an MIT licence. Its only advisory, a ReDoS fixed in 2020, is old, and none came in the last 24 months. The OpenSSF Scorecard is 4.8. Weak spots include almost no code review, no security policy, no branch protection and unsigned releases, and very few people publish it.

  • npm dependencies: 0 dependencies
  • advisories: 1 advisory in total (2020 ReDoS), none in the last 24 months
  • scorecard score: 4.8; weak Code-Review, Security-Policy and Branch-Protection
  • npm license: MIT

GPT-6.2 Sol: 7.2, likely 6.0 to 8.4

The npm package has zero runtime dependencies and an MIT license. The sole recorded high-severity advisory was patched across three release lines, with fixes available before the GitHub advisory appeared and zero advisories recorded in the past 24 months. Scorecard gives Acorn 4.8 out of 10, with weak review and dependency pinning and zero scores for branch protection, a security policy, and fuzzing. The package lists three maintainers, while the publishing controls and signing status remain unverified.

Good

  • It has zero dependencies, ships its own types, and has kept the same 8.x API without breaking changes for years.
  • It tracks new ECMAScript syntax closely. Recent releases added `using`/`await using`, import attributes, Unicode 17 and 18, and `sourceType: "commonjs"`.
  • Its ESTree output is the reference shape that other parsers copy. Oxc, for example, checks its output against Acorn's.
  • Core tools are built on it, such as webpack, ESLint's espree and Svelte, so edge cases get found and fixed fast.

Bad

  • It has no built-in TypeScript parsing. It fails on .ts files unless you add a third-party plugin such as @sveltejs/acorn-typescript.
  • It only parses. To change code you need other tools to walk, transform and print the tree, such as acorn-walk, astring or magic-string.
  • Rust-based Oxc parses several times faster and handles TypeScript and JSX in one package.
  • Plugins hook into Acorn's internals, which the README itself warns can break them.

The numbers

npm downloads, 4 weeks
1.3B ×2.7 in a year
GitHub stars
11k
Commits, 12 months
49
npm version
8.19.0 Oct 2026
Versions, 12 months
4
Advisories, 24 months
0 of 1 ever
OpenSSF Scorecard
4.8 out of 10, Nov 2026
Licence
MIT

Many packages install it, so most downloads are not a direct choice.

Read on 21 November 2026 from GitHub (acornjs/acorn), npm (acorn), OSV and the OpenSSF Scorecard.

JavaScript parsers and codemods

  1. 8.0Babel parser
  2. 7.8Oxc parser
  3. 7.5ast-grep
  4. 7.1Acorn
  5. 7.1Recast
  6. 7.0ts-morph
  7. 6.4jscodeshift
  8. 6.3Meriyah
  9. 2.4Esprima
Compare all 9 on six scores