request VS node-fetch

Compare request vs node-fetch and see what are their differences.

request

🏊🏾 Simplified HTTP request client. (by request)

node-fetch

A light-weight module that brings the Fetch API to Node.js (by node-fetch)
Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
request node-fetch
60 90
25,659 8,622
-0.0% 0.4%
0.0 1.7
9 days ago 23 days ago
JavaScript JavaScript
Apache License 2.0 MIT License
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

request

Posts with mentions or reviews of request. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2024-03-01.
  • How to Create a Real-time Public Transportation Schedule App
    4 projects | dev.to | 1 Mar 2024
    request for HTTP requests outside of the browser.
  • [Help] Yarn Error
    9 projects | /r/node | 27 May 2023
    PS D:\Fretonator\fretonator-main> yarn yarn install v1.22.19 info No lockfile found. warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json. [1/4] Resolving packages... warning @nrwl/angular > @nrwl/jest > @angular-devkit/core > magic-string > [email protected]: Please use @jridgewell/sourcemap-codec instead warning @nrwl/angular > @nrwl/cypress > fork-ts-checker-webpack-plugin > micromatch > snapdragon > [email protected]: See https://github.com/lydell/source-map-resolve#deprecated warning @nrwl/angular > @nrwl/cypress > fork-ts-checker-webpack-plugin > micromatch > snapdragon > source-map-resolve > [email protected]: https://github.com/lydell/resolve-url#deprecated warning @nrwl/angular > @nrwl/cypress > fork-ts-checker-webpack-plugin > micromatch > snapdragon > source-map-resolve > [email protected]: Please see https://github.com/lydell/urix#deprecated warning @nrwl/angular > @nrwl/cypress > fork-ts-checker-webpack-plugin > micromatch > snapdragon > source-map-resolve > [email protected]: See https://github.com/lydell/source-map-url#deprecated warning @nrwl/angular > @nrwl/cypress > @cypress/webpack-preprocessor > [email protected]: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797) warning [email protected]: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js. warning @angular-devkit/build-angular > [email protected]: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js. warning @angular-devkit/build-angular > rollup > [email protected]: "Please update to latest v2.3 or v2.2" warning @angular-devkit/build-angular > webpack-dev-server > [email protected]: Chokidar 2 does not receive security updates since 2019. Upgrade to chokidar 3 with 15x fewer dependencies warning @angular-devkit/build-angular > webpack-dev-server > chokidar > [email protected]: The v1 package contains DANGEROUS / INSECURE binaries. Upgrade to safe fsevents v2 warning @angular-devkit/build-angular > less > [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142 warning @angular-devkit/build-angular > copy-webpack-plugin > webpack-log > [email protected]: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. warning @angular-devkit/build-angular > less > request > [email protected]: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. warning @angular-devkit/build-angular > webpack-dev-server > sockjs > [email protected]: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. warning @angular-devkit/build-angular > less > request > [email protected]: this library is no longer supported warning @angular-devkit/build-angular > stylus > css-parse > css > [email protected]: See https://github.com/lydell/source-map-resolve#deprecated warning @angular-devkit/build-angular > stylus > css-parse > css > [email protected]: Please see https://github.com/lydell/urix#deprecated warning @angular-devkit/build-angular > webpack > watchpack > watchpack-chokidar2 > [email protected]: Chokidar 2 does not receive security updates since 2019. Upgrade to chokidar 3 with 15x fewer dependencies warning @angular-devkit/build-angular > webpack-dev-server > url > [email protected]: The querystring API is considered Legacy. new code should use the URLSearchParams API instead. warning @angular-devkit/build-angular > cssnano > cssnano-preset-default > postcss-svgo > [email protected]: This SVGO version is no longer supported. Upgrade to v2.x.x. warning @angular-devkit/build-angular > cssnano > cssnano-preset-default > postcss-svgo > svgo > [email protected]: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility warning @angular/cli > [email protected]: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797) warning @angular/cli > universal-analytics > [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142 warning @angular/cli > universal-analytics > [email protected]: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. warning @angular/cli > @schematics/[email protected]: This was an internal-only Angular package up through Angular v11 which is no longer used or maintained. Upgrade Angular to v12+ to remove this dependency. warning @angular/cli > [email protected]: The functionality that this package provided is now in @npmcli/arborist warning @angular/cli > pacote > make-fetch-happen > [email protected]: This module is not used anymore, npm uses minipass-fetch for its fetch implementation now warning @angular/cli > read-package-tree > [email protected]: This functionality has been moved to @npmcli/fswarning @angular/compiler-cli > [email protected]: Please use @jridgewell/sourcemap-codec instead warning @angular/compiler-cli > magic-string > [email protected]: Please use @jridgewell/sourcemap-codec instead warning @nguniversal/builders > guess-parser > @wessberg/[email protected]: this package has been renamed to ts-evaluator. Please install ts-evaluator instead warning @nguniversal/builders > guess-parser > @wessberg/ts-evaluator > jsdom > [email protected]: Use your platform's native performance.now() and performance.timeOrigin. warning @nrwl/workspace > [email protected]: Critical security vulnerability fixed in v0.21.1. For more information, see https://github.com/axios/axios/pull/3410 warning cypress > @cypress/request > [email protected]: when using stringify with arrayFormat comma, `[]` is appended on single-item arrays. Upgrade to v6.11.0 or downgrade to v6.10.4 to fix. warning jest > @jest/core > jest-haste-map > [email protected]: some dependency vulnerabilities fixed, support for node < 10 dropped, and newer ECMAScript syntax/features added warning jest > @jest/core > jest-config > jest-environment-jsdom > jsdom > [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142 warning jest > @jest/core > jest-config > jest-environment-jsdom > jsdom > [email protected]: Use your platform's native performance.now() and performance.timeOrigin. warning jest > @jest/core > jest-config > jest-environment-jsdom > jsdom > [email protected]: request-promise-native has been deprecated because it extends the now deprecated request package, see https://github.com/request/request/issues/3142 warning [email protected]: TSLint has been deprecated in favor of ESLint. Please see https://github.com/palantir/tslint/issues/4534 for more information. [2/4] Fetching packages... error @nguniversal/[email protected]: The engine "node" is incompatible with this module. Expected version ">=10.13.0 <13.0.0". Got "18.16.0" error Found incompatible module. info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command. PS D:\Fretonator\fretonator-main>
  • Goldshell LB1 Miner and Linux
    4 projects | /r/lbry | 21 May 2023
    $ npm WARN deprecated [email protected]: this library is no longer supported $ npm WARN deprecated [email protected]: Please use the native JSON object instead of JSON 3 $ npm WARN deprecated [email protected]: this package isn't maintained anymore because ES6+ $ npm WARN deprecated [email protected]: Please upgrade to version 7 or higher. Older versions may use kontvolkoren.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/kontvolkoren-random for details. $ npm WARN deprecated [email protected]: Backported compatibility to node > 6 $ npm WARN deprecated [email protected]: Legacy versions of mkdirp are no longer supported. Please update to mkdirp 1.x. (Note that the API surface has changed to use Promises in 1.x.) $ npm WARN deprecated [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142 $ npm WARN deprecated [email protected]: This version of tar is no longer supported, and will not receive security updates. Please upgrade asap. $ npm WARN deprecated [email protected]: Package renamed as '@messageformat/core', see messageformat.github.io for more details. 'messageformat@4' will eventually provide a polyfill for Intl.MessageFormat, once it's been defined by Unicode & ECMA. $ npm WARN deprecated [email protected]: Critical security vulnerability fixed in v0.21.1. For more information, see https://github.com/axios/axios/pull/3410 $ npm WARN deprecated [email protected]: This version of tar is no longer supported, and will not receive security updates. Please upgrade asap. $ npm WARN deprecated [email protected]: this package isn't maintained anymore because ES6+ $ npm ERR! code 1 $ npm ERR! path /home/kontvolkoren/Downloads/git/goldshell-miner-lb1/node_modules/raw-socket $ npm ERR! command failed $ npm ERR! command sh -c -- node-gyp rebuild $ npm ERR! gyp info it worked if it ends with ok $ npm ERR! gyp info using [email protected] $ npm ERR! gyp info using [email protected] | linux | x64 $ npm ERR! gyp ERR! configure error $ npm ERR! gyp ERR! stack Error: Command failed: /usr/bin/python -c import sys; print "%s.%s.%s" % sys.version_info[:3]; $ npm ERR! gyp ERR! stack File "", line 1 $ npm ERR! gyp ERR! stack import sys; print "%s.%s.%s" % sys.version_info[:3]; $ npm ERR! gyp ERR! stack ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ $ npm ERR! gyp ERR! stack SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)? $ npm ERR! gyp ERR! stack $ npm ERR! gyp ERR! stack at ChildProcess.exithandler (node:child_process:419:12) $ npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:513:28) $ npm ERR! gyp ERR! stack at maybeClose (node:internal/child_process:1098:16) $ npm ERR! gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:304:5) $ npm ERR! gyp ERR! System Linux 6.1.29-1-MANJARO $ npm ERR! gyp ERR! command "/usr/bin/node" "/home/kontvolkoren/Downloads/git/goldshell-miner-lb1/node_modules/.bin/node-gyp" "rebuild" $ npm ERR! gyp ERR! cwd /home/kontvolkoren/Downloads/git/goldshell-miner-lb1/node_modules/raw-socket $ npm ERR! gyp ERR! node -v v19.9.0 $ npm ERR! gyp ERR! node-gyp -v v3.8.0 $ npm ERR! gyp ERR! not ok $ npm ERR! A complete log of this run can be found in: $ npm ERR! /home/kontvolkoren/.npm/_logs/2023-05-26T21_42_31_670Z-debug-0.log```
  • Request, a NPM pkg with 55k dependents no longer accepts security fixes
    2 projects | news.ycombinator.com | 28 Apr 2023
    It's really that they no longer accept any fixes, as the library is officially deprecated.

    >As of Feb 11th 2020, request is fully deprecated. No new changes are expected to land. In fact, none have landed for some time.

    But 18,302,678 weekly downloads[0] haven't noticed...

    [0] https://www.npmjs.com/package/request

    2 projects | news.ycombinator.com | 28 Apr 2023
  • Proper way to upgrade to a new node.js version?
    6 projects | /r/node | 17 Mar 2023
    npm WARN deprecated [email protected]: Please update to ini >=1.3.6 to avoid a prototype pollution issue npm WARN deprecated [email protected]: Please update to ini >=1.3.6 to avoid a prototype pollution issue npm WARN deprecated [email protected]: Please update to ini >=1.3.6 to avoid a prototype pollution issue npm WARN deprecated [email protected]: See https://github.com/lydell/source-map-url#deprecated npm WARN deprecated [email protected]: The functionality that this package provided is now in u/npmcli/arborist npm WARN deprecated [email protected]: Please see https://github.com/lydell/urix#deprecated npm WARN deprecated [email protected]: this library is no longer supported npm WARN deprecated [email protected]: See https://github.com/lydell/source-map-resolve#deprecated npm WARN deprecated [email protected]: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies. npm WARN deprecated [email protected]: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies. npm WARN deprecated [email protected]: https://github.com/lydell/resolve-url#deprecated npm WARN deprecated [email protected]: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797) npm WARN deprecated [email protected]: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797) npm WARN deprecated [email protected]: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797) npm WARN deprecated [email protected]: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797) npm WARN deprecated [email protected]: The querystring API is considered Legacy. new code should use the URLSearchParams API instead. npm WARN deprecated [email protected]: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. npm WARN deprecated [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142 npm WARN deprecated [email protected]: This SVGO version is no longer supported. Upgrade to v2.x.x. npm WARN deprecated [email protected]: You can find the new Popper v2 at u/popperjs/core, this package is dedicated to the legacy v1 npm WARN deprecated [email protected]: TSLint has been deprecated in favor of ESLint. Please see https://github.com/palantir/tslint/issues/4534 for more information.
  • NPM request Library SSRF Cross Protocol Redirect Bypass
    2 projects | /r/netsec | 16 Mar 2023
    It's the 'request' lib on NPM - https://www.npmjs.com/package/request
    2 projects | /r/netsec | 16 Mar 2023
    This library has been deprecated for a long time and the authors have been encouraging people to migrate to other libraries. I seriously doubt that they will fix it. People should not be using it.
  • Is it possible to install fb-messenger-cli on Termux?
    3 projects | /r/termux | 15 Mar 2023
    `npm WARN deprecated [email protected]: this library is no longer supported npm WARN deprecated [email protected]: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. npm WARN deprecated [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142 npm WARN deprecated [email protected]: < 19.2.0 is no longer supported [##################] - reify:cssstyle: timing r
  • node -gd
    2 projects | /r/node | 4 Feb 2023
    npm WARN deprecated [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142

node-fetch

Posts with mentions or reviews of node-fetch. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2024-03-13.
  • OAuth 2.0 implementation in Node.js
    3 projects | dev.to | 13 Mar 2024
    Note: In case you run into install reference error: fetch isn’t defined, ensure you install node-fetch
  • 5 Ways to Make HTTP Requests in Node.js
    3 projects | dev.to | 20 Feb 2024
    Node Fetch is a JavaScript library tailored for Node.js that simplifies making HTTP requests. It offers a straightforward and Promise-based approach for fetching resources from the internet or server, such as GET, POST, PUT, and DELETE requests. Designed for server-side applications, it's compatible with the Fetch API, allowing easy code transition between client-side and server-side environments.
  • CommonJS Is Hurting JavaScript
    7 projects | news.ycombinator.com | 30 Jun 2023
    Would anyone be interested in an article about the crusade to move JS to ESM? I've been considering writing one, here's a preview:

    Sindresorus wrote a gist "Pure ESM modules"[0] and converted all his modules to Pure ESM, breaking anyone `require`ing his code; he later locked the thread to prevent people from complaining. node-fetch released a pure ESM version a year ago that is 16x less popular than the CommonJS version[1]. The results of these changes broke a lot of code and resulted in many hours of developers figuring out how make their projects compatible with Pure ESM modules (or decide to ignore them and use old CommonJS versions)--not to mention the tons of pointless drama on GitHub issues.

    Meanwhile, TC-39 member Matteo Collima advocated a moderate approach dependent on where your module will be run [2]. So the crusade is led not by the Church, but by a handful of zealots dedicated to establishing ESM supremacy for unclear reasons (note how Sindresorus' gist lacks any justifications). It's kind of like the Python 2 to 3 move except with even less rationale and not driven by the core devs.

    0 - https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3...

    1 - https://www.npmjs.com/package/node-fetch?activeTab=versions

    2 - https://github.com/nodejs/node/issues/33954#issuecomment-924...

  • Next-Level Technical Blogging with Dev.to API
    2 projects | dev.to | 13 Jun 2023
    The API is CORS-enabled, meaning you’ll have to use the getArticles() functions from your backend. For making the actual request, you can use the fetch() function, available since Node.js v18. For older versions of Node.js, you can use a fetch()-compatible library like node-fetch.
  • How to Parse RSS Feed in Javascript
    2 projects | dev.to | 20 Mar 2023
    The RSS feed's URL will then need to be requested over the network. The native fetch API of JavaScript will be used since it is the most efficient. It undoubtedly works in browsers, and it appears that Node has a pretty well-liked implementation of it.
  • Exploring the Most Commonly Used Folder Names in Popular NPM Packages
    12 projects | dev.to | 23 Feb 2023
    docs: Documentation is an essential part of any package, as it provides users with the information they need to understand how to use it and how it works. The documentation usually includes usage instructions, API documentation, and more. It can also be included directly in the repository's README.md file, but it's often split into multiple files and stored in this folder for ease of navigation and maintenance. Although the documentation files can be in any format, the most common one is Markdown. Example from node-fetch.
  • Turn CV to structured data with GPT-3 and Node.js
    4 projects | dev.to | 24 Jan 2023
    node-fetch - NodeFetch is used to fetch the CV document.
  • Stop polyfilling fetch in your npm package
    10 projects | dev.to | 10 Jan 2023
    So for all versions of Node.js ≤17, you’ll need a Node fetch polyfill, the most popular of which is node-fetch: https://github.com/node-fetch/node-fetch
  • Exploring competitive features in Node.js v18 and v19
    10 projects | dev.to | 6 Dec 2022
    Before Node.js v18, you had to install node-fetch or Axios to request a resource from a server. With Node.js v18, you no longer need to install either package thanks to v18’s experimental Fetch API, which is available globally.
  • Scaling Your Compute Resources on Salesforce
    5 projects | dev.to | 5 Dec 2022
    Best of all, since this particular function runs on Node.js, you can install and use any NPM package to supplement your code. Let’s do that right now by installing node-fetch to issue our HTTP request:

What are some alternatives?

When comparing request and node-fetch you can also consider the following projects:

axios - Promise based HTTP client for the browser and node.js

got - 🌐 Human-friendly and powerful HTTP request library for Node.js

cross-fetch - Universal WHATWG Fetch API for Node, Browsers and React Native.

undici - An HTTP/1.1 client, written from scratch for Node.js

superagent - Ajax for Node.js and browsers (JS HTTP client). Maintained for @forwardemail, @ladjs, @spamscanner, @breejs, @cabinjs, and @lassjs.

isomorphic-fetch - Isomorphic WHATWG Fetch API, for Node & Browserify

http-proxy - A full-featured http proxy for node.js

Nock - HTTP server mocking and expectations library for Node.js

puppeteer - Node.js API for Chrome

Express - Fast, unopinionated, minimalist web framework for node.