Node.js built-in modules
Modules that come with Node.js itself, such as fs, path, crypto and child_process.
In more detail
They need no installation and are imported by name, optionally with the node: prefix, such as node:fs. Other JavaScript runtimes support some of them for compatibility.
Example
The Next.js Edge runtime supports only a few Node.js modules and relies on Web APIs instead.Related terms
- node:fs — The built-in Node.js module for working with files and folders, in promise, callback and synchronous forms.
- Node.js runtime — The default Next.js runtime, where server code runs on Node.js with access to every Node API and npm package.
- Edge runtime — A lightweight Next.js runtime based on V8 isolates and standard Web APIs, which starts almost instantly but cannot use most Node.js APIs.
Taught in
- Runtime Environments: Node.js vs Edge Runtime Choice — Next.js 15 & Modern App Router Architecture