# zx: 7.2 out of 10

A strong pick. 3rd of 8 in [Shell and process tools](https://elestia.ai/opensource/shell/index.md).

zx is a Node.js scripting tool from the google GitHub organisation. It lets you write bash-style commands as JavaScript template literals, with escaping, piping, globbing and fetch included. It is still the most popular way to turn shell scripts into Node.js scripts, but it has had no release in 13 months and its downloads are growing more slowly than the category.

**Best for:** Teams on Node.js who want to replace growing bash scripts with JavaScript or TypeScript and keep shell syntax.

## Scores

- **Overall: 7.2** (likely 6.0 to 8.2)
  - Claude Opus 5.5 (7.0): zx is still the strongest choice for writing shell-style scripts in JavaScript on Node.js, with a mature API and wide runtime support. The 13 months without a release, a small core team and growth below the median keep it out of the 8+ range. Bun users have Bun Shell built in, and application code is better served by execa or tinyexec.
  - GPT-6.2 Sol (7.3): zx is a strong choice for new automation that mixes real shell pipelines with JavaScript control flow. Execa is the stronger general-purpose pick for portable process execution, and Bun Shell is convenient for Bun-only teams. The year-long release gap and below-median download growth lower confidence in zx as a category default.
- **Needed by many: 5.6** (likely 4.2 to 6.9)
  - Claude Opus 5.5 (5.5): Many JS developers write build, release or automation scripts, but zx serves the scripting side of the category, not process spawning inside apps. That makes it narrower than execa or cross-spawn. It does work on Node.js, Bun and Deno.
  - GPT-6.2 Sol (5.6): Build, release, and CI automation give zx a role across many kinds of JavaScript projects, and it supports several major runtimes. Its shell-first API is most useful when scripts need to coordinate multiple commands. Runtime surveys give a sense of the potential audience, while the share that needs dedicated scripting tools is harder to estimate.
- **Helps a lot: 7.8** (likely 6.7 to 8.8)
  - Claude Opus 5.5 (7.5): zx has a rich, ergonomic API: piping (including many-to-one and unpipe), nothrow, timeouts, kill handling, sync mode and a script runner. Its types and documentation are good. Its limits are that it depends on the host shell, Windows support is uneven, cd is global and output is buffered. Bun Shell's builtins are faster and cross-platform, but only on Bun.
  - GPT-6.2 Sol (8.0): Version 8.8.5 makes shell pipelines, streaming, timeouts, and exit errors easy to handle from JavaScript. The built-in types and documented examples give coding agents a clear API to follow. Shell behavior still varies across systems, and Wasp had to bypass `json()` because it mixes stdout and stderr. Recent performance and coding-agent accuracy measurements are sparse.
- **Holds up over time: 5.9** (likely 4.4 to 7.4)
  - Claude Opus 5.5 (6.0): Commits continued through November 2026 (52 in the last year) and only 14 issues are open, so the project is not abandoned. But nothing has been released for 13 months, and almost all the work comes from two maintainers. A v9 is only mentioned as tentative. The project lives under the google organisation, but no clear corporate funding is visible.
  - GPT-6.2 Sol (5.7): The repository saw 52 commits in the past year, and maintainers discussed publishing changes in November 2026. Stable releases have stalled since October 2025 while Execa and Dax have shipped new versions. The v8 upgrade changed logging defaults and removed the SSH helper, with a migration guide covering both. Future release cadence and long-term staffing are uncertain.
- **Used widely: 5.1** (likely 4.0 to 6.3)
  - Claude Opus 5.5 (6.0): zx has about 11.7M downloads in 4 weeks and 2,228 dependent repos. Those numbers are small next to execa and cross-spawn but come mostly from direct choices. Its 2.35x yearly ratio is below the 4.1x median, so it is losing relative ground. Its 45.9k stars are the most of any dedicated tool in the category.
  - GPT-6.2 Sol (4.2): Ecosyste.ms found 2,228 dependent repositories and 1,354 npm packages, far below Execa and ShellJS despite zx's roughly 46,000 stars. Four-week downloads rose from 5.0 million to 11.7 million, or 2.35 times, below the catalog's 4.1 times median. The indexed dependents show thousands of projects using zx, while private scripts and automated reinstalls make current direct adoption hard to estimate.
- **Vouched for: 6.4** (likely 4.9 to 7.6)
  - Claude Opus 5.5 (6.0): Independent 2026 comparisons, in English and Japanese, recommend zx as the default for Node.js scripting. It also has a large star count and steady mentions from developers. There are no survey satisfaction numbers specific to zx, and few named production users. Hacker News and Bluesky attention is low.
  - GPT-6.2 Sol (6.7): Vue's scaffolder uses zx for testing and releases, and VS Code lists it in its build tooling. Wasp uses it to drive deployment CLIs and documented a workaround for output parsing. These are concrete examples of use in maintained projects. Broad satisfaction data and recent independent benchmarks are scarce.
- **Safe: 7.4** (likely 6.3 to 8.4)
  - Claude Opus 5.5 (7.0): zx installs no npm dependencies, uses the Apache-2.0 licence and has an OpenSSF Scorecard of 7.1. Its two moderate advisories (dotenv env injection, and node_modules deletion with --prefer-local) both have fixed versions, and the 8.8.x releases hardened it against command injection. Code review is weak (Scorecard 2), and because it runs commands through a shell, interpolating untrusted input is risky.
  - GPT-6.2 Sol (7.7): The Apache-2.0 package installs no separate npm dependencies and bundles third-party code. Both moderate advisories were fixed by public disclosure, and 8.8.5 includes both fixes. The release workflow publishes through Google's npm proxy with provenance. The 7.1 Scorecard shows weak code review and no detected fuzzing, and the number of people who can publish independently is unclear.

## Good

- The $`cmd` template literal escapes values you interpolate, and you can run commands in parallel with Promise.all.
- It includes everything a script needs: fetch, glob, chalk, YAML, minimist, retry, spinner and a CLI runner for .mjs and markdown scripts.
- It runs on Node.js, Bun and Deno, ships its own types and installs no npm dependencies.
- Its API is mature and well documented, and AI coding agents write correct code for it.

## Bad

- The last release (8.8.5) came out in October 2025, so fixes made on main since then are not published.
- It runs commands through the host shell, so behaviour on Windows differs unless you use Git Bash or WSL, and it is unsafe with untrusted input.
- It is heavier than execa or tinyexec when you only need to spawn a process from application code.
- Its downloads grew 2.35x in a year, below the 4.1x median, so it is losing share to Bun Shell and lighter tools.

## The numbers

- Downloads, 4 weeks: 12M
- In a year: ×2.4
- GitHub stars: 46k
- Commits, 12 months: 52
- Last npm release: Oct 2025
- Advisories, 24 months: 2
- Licence: Apache-2.0
- GitHub: https://github.com/google/zx
- npm: https://www.npmjs.com/package/zx

Scores run from 0 to 10 and are the mean of the scores of AI reviewers (Claude Opus 5.5, GPT-6.2 Sol), made on 22 November 2026 from GitHub, npm, OSV, OpenSSF Scorecard, ecosyste.ms, Hacker News and Bluesky data and a web search. The ecosyste.ms count of repositories that use a project is far too low for projects that grew in the last few years, and some reviews quote it. Overall is the reviewers' own judgement for a new project today, not an average of the parts. An AI wrote them and can be wrong.
