Node.js documented errors
Browse documented Node.js errors with exact messages, troubleshooting context, and practical remediation steps.
Filesystem
Filesystem errors
ENOENTNode.js could not find the requested file or directoryNode.js tried to access a path that does not exist at the time of the operation.
ENOTDIRNode.js expected a directory but found a file path insteadNode.js attempted to traverse or open a path as a directory, but one of the path segments is not actually a folder.
EISDIRNode.js expected a file but received a directory pathNode.js attempted a file-oriented operation on a path that actually points to a directory.
EEXISTNode.js tried to create a file or directory that already existsNode.js attempted an operation that requires a path not to exist yet, but that file or directory was already present.
Http
Http errors
Modules
Modules errors
ERR_PACKAGE_PATH_NOT_EXPORTEDNode.js blocked access to a package subpath that is not exportedNode.js found the package, but the requested subpath is not exposed through the package exports field, so the import is blocked.
ERR_MODULE_NOT_FOUNDNode.js could not resolve the requested moduleNode.js could not resolve an import or module specifier, usually because the path, package name, export map, or file extension does not match what the runtime expects.
ERR_REQUIRE_ESMNode.js require tried to load an ES moduleNode.js rejected a require() call because the target module is an ES module and the current loading path is not compatible with it.
Network
Network errors
ECONNREFUSEDNode.js connection was refused by the target serviceNode.js tried to connect to a remote service, but nothing accepted the connection at the target host and port.
ECONNRESETNode.js connection was reset by the peerNode.js was communicating over a socket, but the remote side closed the connection unexpectedly before the exchange completed.
EADDRINUSENode.js could not bind because the address is already in useNode.js could not start a server because another process is already listening on the same host and port combination.
ETIMEDOUTNode.js operation timed out before completionNode.js waited too long for a network or socket operation to complete and the operation timed out.
Runtime
Runtime errors
EMFILENode.js opened too many files at onceNode.js reached the operating system limit for open file descriptors, which commonly happens during heavy file access or runaway watchers.
EACCESNode.js permission denied while accessing a file or resourceNode.js could not access a file, folder, port, or other resource because the current process does not have the required permissions.
ERR_INVALID_ARG_TYPENode.js received an argument with the wrong typeNode.js threw because an API received a value of the wrong type, such as a string where a Buffer, URL, or function was expected.
ERR_INVALID_ARG_VALUENode.js received an unsupported argument valueNode.js rejected an argument because the value was structurally the right kind of thing, but the content was not valid for that API.