Softwr

Web Development · head to head

Gatsby vs npm

Gatsby logo

Gatsby

Web Development

Open-source React framework for building websites and apps

From
Free
Free plan
Yes
npm logo

npm

Web Development

Package manager for JavaScript

From
Free
Free plan
Yes

The short version

  • Gatsby is free; npm starts at $7/mo.
  • Only Gatsby lists react-based component development; only npm lists package installation.
  • Where Gatsby falls short: Gatsby Cloud hosting ended in August 2023 and was merged into Netlify.
  • Where npm falls short: private packages require a paid user or organization account; the free registry publishes publicly only.

How do Gatsby and npm differ?

Gatsby and npm differ on pricing model (Open-source against Freemium) and platforms. Only the attributes on which Gatsby and npm actually diverge.

Attributes where Gatsby and npm differ
AttributeGatsbynpm
Pricing modelOpen-sourceFreemium
PlatformsWeb, Windows, macOS, LinuxWindows, macOS, Linux

Identical on both: starting price (Free), free tier (Yes), category (Web Development).

Not yet recorded: founded for Gatsby.

Which features does each one have?

They share no listed features; 8 appear only for Gatsby and 20 only for npm. Drawn from each product's published feature list. An absence here means we hold no record of it - not that the product lacks it.

Only in Gatsby

  • React-based component development
  • GraphQL data layer
  • Plugin and theme ecosystem
  • Static site generation
  • Server-side rendering
  • Deferred Static Generation
  • Headless CMS integration
  • Cloud Functions support

Only in npm

  • Package installation
  • Dependency management
  • Version management
  • Script running
  • Package publishing
  • Security auditing
  • Package discovery
  • CLI interface

What is each one used for?

Gatsby is most often brought in for marketing sites pulling content from a headless CMS; npm for package management. The jobs each tool is most often brought in to do.

Gatsby

  • Marketing sites pulling content from a headless CMSnot npm
  • Blogs and documentation sites built in Reactnot npm
  • Static sites with image optimisation pluginsnot npm
  • Migrating existing Gatsby Cloud sites to Netlifynot npm

npm

  • Package managementnot Gatsby
  • Dependency installationnot Gatsby
  • Project scaffoldingnot Gatsby
  • Build automationnot Gatsby
  • Package publishingnot Gatsby
  • Version controlnot Gatsby

Where do Gatsby and npm fall short?

Gatsby's most cited limit: Gatsby Cloud hosting ended in August 2023 and was merged into Netlify. npm's: private packages require a paid user or organization account; the free registry publishes publicly only. Documented limitations, not opinions. Every one is a constraint you would hit in normal use.

Gatsby

  • Gatsby Cloud hosting ended in August 2023 and was merged into Netlify
  • The GitHub repository's releases section is empty, so release cadence is unclear
  • Requires React and GraphQL knowledge; there is no visual editor
  • Hosting, CMS and build services are paid separately
  • Official hosting guidance now centres on Netlify

npm

  • Private packages require a paid user or organization account; the free registry publishes publicly only
  • Publishing needs an account with 2FA enabled or a granular access token with bypass 2FA enabled
  • Only scoped packages can be made private (--access=restricted); unscoped packages cannot be restricted
  • A package name and version can never be reused once published, even after npm unpublish

How much do Gatsby and npm cost?

Gatsby is free to use; npm has a free plan, with paid plans from $7/mo. Plan by plan below, from each vendor's own pricing page.

Gatsby

Free

No published plan breakdown. See the Gatsby review.

npm

Free
  • FreeFree
    • Unlimited public packages
    • Package discovery
    • npm CLI
  • Pro$7/mo
    • Unlimited private packages
    • Package analytics
    • Support
  • Teams$7/mo
    • Team management
    • Organization packages
    • Audit logs

Which should you pick?

Choose Gatsby if

  • You need react-based component development.
  • You want to start without paying.
  • You work on Web, Windows, macOS, Linux.
  • You also want graphql data layer.

Choose npm if

  • You need package installation.
  • You want to start without paying.
  • You work on Windows, macOS, Linux.
  • You also want dependency management.

Questions people ask

Is Gatsby or npm better?
It depends on the job. Gatsby fits marketing sites pulling content from a headless CMS; npm fits package management. Gatsby starts at Free and npm at Free.
Which is cheaper, Gatsby or npm?
Gatsby starts at Free and npm at Free.
Does Gatsby or npm run on more platforms?
Gatsby runs on Web, Windows, macOS, Linux. npm runs on Windows, macOS, Linux.
Can I use Gatsby for free?
Both have a free tier, so you can try either at no cost before committing.
What is Gatsby best used for?
Gatsby is most often used for marketing sites pulling content from a headless cms, blogs and documentation sites built in react, static sites with image optimisation plugins, migrating existing gatsby cloud sites to netlify. Of those, marketing sites pulling content from a headless cms and blogs and documentation sites built in react are not what npm is typically brought in for.
What can Gatsby do that npm cannot?
Gatsby covers React-based component development, GraphQL data layer, Plugin and theme ecosystem, Static site generation. npm covers Package installation, Dependency management, Version management, Script running.

Answered from the vendors’ own pages

Gatsby: Is Gatsby free?

Yes. Gatsby is open source under the MIT License, and the project site lists no paid Gatsby plans. You pay separately for hosting and any CMS you connect.

Source
npm: Is npm free to use?

Installing and sharing public packages on npm is free. Using and sharing private packages requires upgrading your account to a paid plan. Organisations can be public (free) or private (paid).

Source
Gatsby: What happened to Gatsby Cloud?

Netlify acquired Gatsby, Inc. in February 2023 and ended Gatsby Cloud in August 2023, folding it into Netlify. The Gatsby site offers migration paths to Netlify.

Source
npm: How do I publish a private package on npm?

For a user-scoped private package you need a paid npm user account. For an organisation-scoped one you need a user account and a paid organisation. Scoped packages are published as private by default under those conditions, and you can set --access=restricted on a scoped package.

Source
Gatsby: Does Gatsby support server-side rendering?

Yes. Wikipedia says version 4 added server-side rendering and Deferred Static Generation alongside static generation. The Gatsby site also mentions Cloud Functions.

Source
npm: Do I need two-factor authentication to publish to npm?

Publishing requires either a 2FA-enabled account or a granular access token with bypass 2FA enabled. Account-identity and governance actions cannot be done with a bypass-2FA token from August 2026.

Source
npm: Can I republish a version after unpublishing it from npm?

No. Publishing fails if the name and version already exist in the registry, and that combination can never be used again even after npm unpublish. You must publish a new version number.

Source
npm: Who owns npm?

npm, Inc. runs both the package manager and the registry. It is a subsidiary of GitHub, which acquired it in March 2020 and is itself owned by Microsoft.

Source
Share

Related pages

Other head to heads