npm fund

In November 2019, npm introduced the npm fund command. If you've run npm install recently, you've seen the gentle reminder: "4 packages are looking for funding. Run npm fund for details."

As npm’s former CEO, Isaac Schlueter, noted, maintainers have historically had “very few ways to get funding information in front of the people using their code.” The npm fund command addresses this through three complementary design principles:

  1. Timely prompts: The reminder appears right after npm install completes—when developers have just downloaded dependencies and are about to use them. This leverages the psychological principle of temporal relevance, surfacing information when its value is most salient.
  2. Progressive disclosure: The notice is a single, ignorable line. Users can suppress it permanently via --no-fund or a .npmrc setting. The actual list of dependencies seeking support is hidden until you explicitly ask for it. This keeps the install output uncluttered.
  3. Minimal interaction cost: Typing npm fund prints a collapsed tree of packages and their funding links; duplicates are grouped so you don’t see the same URL over and over. Running npm fund <package> opens that package’s funding page in your default browser, and the --which flag lets you choose between multiple funding sources. The path from awareness to action requires only a single command.

Under the hood, npm relies on metadata that maintainers add to package.json. Because npm fund builds on standard metadata, maintainers can expose funding links without code changes. This solves the maintainer‑side frictions.

Mind the Gap

Here's the fascinating part: most other package managers have the infrastructure for funding metadata but lack the user-facing tooling.

Python supports funding URLs in pyproject.toml metadata, and PyPI exposes these through its JSON API, but has no built-in pip fund command. R packages can include funder fields in DESCRIPTION files, but CRAN has no discovery tools. Rust has funding fields in Cargo.tomlbut no equivalent to npm fund. Ruby gems can specify funding URIs but RubyGems lacks integrated discovery.

In other words, the data exists—the maintainer can declare a funding link—but the equivalent of npm’s timely prompt is missing. Tools likee pip-fund (see here) attempt to fill this gap, but they don't integrate with pip, etc., directly.

The Broader Pattern

The same principles apply to other forms of metadata. In academic software, developers often include citation information in their package metadata, yet researchers rarely see it. Some R packages now show citation reminders via .onAttach messages when loaded, using the same “timely prompt” principle to a different metadata problem (see here).

Subscribe to Gojiberries

Don’t miss out on the latest issues. Sign up now to get access to the library of members-only issues.
jamie@example.com
Subscribe