fastify
npmv5.12.3TypeScriptFast and low overhead web framework, for Node.js
Adopt with care
fastify is usable, with caveats. Pulls in 32 transitive packages, about 5.1 MB installed (at least — some of the tree is still being crawled).
- AAdoption: grade A, Excellent.
8.9M downloads per week and 4 known dependents.
- AMaintenance: grade A, Excellent.
Last published 5 days ago. 41 releases in the last 2 years.
- CWeight: grade C, Fair — worth a look.
Pulls in 32 transitive packages, about 5.1 MB installed (at least — some of the tree is still being crawled).
- ASupply chain: grade A, Excellent.
No install scripts, 6 maintainers, and a contained dependency surface.
- ALicense: grade A, Excellent.
MIT — permissive, with no copyleft found in the dependency tree.
Grades are computed deterministically from registry metadata collected by PackageGraph — downloads, dependents, publish dates, the resolved dependency tree, maintainer count, and declared licenses. No third-party scores are used.
Install cost
What you actually take on by adding fastify to a project.
Runtime packages this one declares itself.
Distinct packages in the full runtime tree, deduplicated the way a package manager would.
Unpacked size of this package plus its entire runtime tree.
Longest resolved dependency chain below this package.
Part of this dependency tree has not been crawled yet, so these figures are a lower bound rather than a final total.
Licenses in the dependency tree
Every license you inherit by installing fastify, not just its own. Check this before a legal review, not after.
Compatibility
- Node.js
- No constraint declared
- Module format
- CommonJS only
- TypeScript
- Types included
- Install scripts
- None
Quick start
A usage example from the fastify README.
// Require the framework and instantiate it
// ESM
import Fastify from 'fastify'
const fastify = Fastify({
logger: true
})
// CommonJS
const fastify = require('fastify')({
logger: true
})
// Declare a routefastify vs the alternatives
Packages solving a similar problem in the npm ecosystem, compared on the signals that drive an adoption decision.
| Package | Weekly downloads | Dependents | License | Last release |
|---|---|---|---|---|
| fastifythis page | 8.9M | 4 | MIT | 5 days ago |
| zod-to-json-schema | 0 | 1 | ISC | 1 day ago |
| express | 92.8M | 17 | MIT | 1 day ago |
| next | 40.6M | 0 | MIT | 1 day ago |
| koa | 6.8M | 0 | MIT | 1 day ago |
| hono | 0 | 4 | MIT | 1 day ago |
Dependencies
Declared by fastify v5.12.3. Runtime dependencies are installed with the package; dev dependencies are not.
Runtime (15)
Dev (35)
Used by
Popular packages that depend on fastify.
Build and manage the fast-json-stringify instances for the fastify framework
Build and manage the AJV instances for the fastify framework
Seamless REST/GraphQL API mocking library for browser and Node.js.
Universal Server.
Relationship graph
Dependencies (left) and dependents (right) of fastify.
Frequently installed together
An HTTP/1.1 client, written from scratch for Node.js
Fast, unopinionated, minimalist web framework
Next generation testing framework powered by Vite
TypeScript definitions for node
TypeScript typings for Cloudflare Workers
JavaScript implementations of network transports, cryptography, ciphers, PKI, message digests, and various utilities.
Get an available TCP port to listen
Node.js Adapter for Hono
V8 coverage provider for Vitest
An AST-based pattern checker for JavaScript.
Require module from string
Dependency-free RFC 3986 URI toolbox
Release history
39 releases in the last two years, typically about 3 days apart.
| Version | Published | Size | License |
|---|---|---|---|
| 6.0.0-alpha.3 | 5 days ago | 2.8 MB | MIT |
| 5.12.3latest | 5 days ago | 2.8 MB | MIT |
| 5.12.2 | 5 days ago | 2.8 MB | MIT |
| 6.0.0-alpha.2 | 22 days ago | 2.8 MB | MIT |
| 5.12.1 | 22 days ago | 2.8 MB | MIT |
| 5.12.0 | 27 days ago | 2.8 MB | MIT |
| 6.0.0-alpha.1 | 27 days ago | 2.7 MB | MIT |
| 6.0.0-alpha.0 | 29 days ago | 2.7 MB | MIT |
| 5.11.3 | 1 month ago | 2.8 MB | MIT |
| 5.11.2 | 1 month ago | 2.8 MB | MIT |
| 5.11.1 | 1 month ago | 2.8 MB | MIT |
| 5.11.0 | 1 month ago | 2.8 MB | MIT |
| 5.10.0 | 2 months ago | 2.7 MB | MIT |
| 5.9.0 | 2 months ago | 2.7 MB | MIT |
| 5.8.5 | 4 months ago | 2.6 MB | MIT |
Overview
fastify is an npm package that fast and low overhead web framework, for Node.js. It is extremely widely used, with about 8.9M downloads per week and 4 known dependents in the graph. The latest version is 5.12.3, released under the MIT license.
Who should use it
Teams working in the npm ecosystem who need fast and low overhead web framework, for Node.js and value a battle-tested, widely-adopted solution.
When not to use it
Consider an alternative if you need to minimize your dependency tree, or if a more actively-maintained option better fits your npm stack.
Pros
- Large, well-established user base (8.9M weekly downloads).
- Ships TypeScript type definitions.
- Clear open-source license (MIT).
Cons
- Large dependency tree (50 direct dependencies) increases install size and audit surface.
Auto-generated from collected registry metadata. No external claims are inferred.
Funding
Frequently asked questions
Should I use fastify?
fastify is usable, with caveats. Pulls in 32 transitive packages, about 5.1 MB installed (at least — some of the tree is still being crawled).
How do I install fastify?
Run `npm install fastify` to add fastify to your npm project.
How many dependencies does fastify have?
fastify declares 50 direct dependencies and pulls in 32 packages in total once its runtime tree is resolved totalling about 5.1 MB on disk.
What license is fastify released under?
fastify is distributed under the MIT license. Its dependency tree also includes: BSD-3-Clause, ISC, MIT.
How popular is fastify?
fastify has approximately 8,946,475 downloads per week and 4 known dependent packages.
Is fastify still maintained?
The most recent release of fastify (v5.12.3) was published 5 days ago.
Does fastify run install scripts?
No. fastify does not define preinstall, install, or postinstall scripts, so installing it does not execute publisher-supplied code.