# npm Packages Scraper - Downloads, Maintainers and Repos (`turboextract/npm-packages`) Actor

Export npm packages by keyword or name: weekly and monthly downloads, version, license, keywords, maintainers, repository, homepage, dependents, publish dates and quality scores. For devtool market research, competitor tracking and developer leads. No API key.

- **URL**: https://apify.com/turboextract/npm-packages.md
- **Developed by:** [Moses Ndambuki](https://apify.com/turboextract) (community)
- **Categories:** Developer tools, Lead generation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$0.50 / 1,000 package delivereds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## npm Packages Scraper: Downloads, Versions, Maintainers and Repos

**Export npm packages by keyword or exact name, with weekly and monthly downloads, latest version, license, keywords, maintainers, repository, homepage, dependents, version count, created and last published dates, TypeScript and ESM flags, and npm's quality scores.** Research a JavaScript niche, track competitors' adoption or find active maintainers. No API key.

In one test, the search "web scraper" plus react and @apify/log returned 10 packages with full details in about 3 seconds.

***

### Who this is for

- **Devtool founders and marketers** measuring adoption against competitors
- **Developer relations teams** tracking their SDK downloads weekly
- **Engineers** comparing libraries before choosing one
- **Investors and analysts** sizing open-source ecosystems
- **Recruiters and partnerships teams** finding active maintainers

***

### What you get

```json
{
  "name": "ts-web-scraper",
  "url": "https://www.npmjs.com/package/ts-web-scraper",
  "description": "A powerful web scraper for both static and client-side rendered sites using only Bun native APIs",
  "version": "0.1.10",
  "weeklyDownloads": 10781,
  "monthlyDownloads": 87028,
  "dependents": 3,
  "license": "MIT",
  "maintainers": ["chrisbreuer"],
  "repository": "https://github.com/stacksjs/ts-web-scraper",
  "versionCount": 10,
  "created": "2025-10-14T23:23:39.746Z",
  "lastPublished": "2026-08-07T19:08:58.914Z",
  "types": true,
  "module": "esm"
}
```

***

### How it works

```mermaid
flowchart LR
    A[Keywords] --> C[npm search]
    B[Package names] --> D[npm registry]
    C --> D
    D --> E[npm downloads API]
    E --> F[Filter: weekly downloads]
    F --> G[Package rows]
```

***

### Quick start

1. Click **Try for free**.
2. Add **Search keywords**, like `react table` or `keywords:llm`.
3. Or add exact **Package names**, like `axios` or `@apify/client`.
4. Optional: set **Minimum weekly downloads**.
5. Click **Start**, then export to CSV, JSON, Excel or Google Sheets.

#### API

```bash
curl -X POST "https://api.apify.com/v2/acts/Turboextract~npm-packages/run-sync-get-dataset-items?token=YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"searchQueries": ["keywords:llm"], "minWeeklyDownloads": 1000, "maxResults": 250}'
```

#### Python

```python
from apify_client import ApifyClient

client = ApifyClient("YOUR_TOKEN")
run = client.actor("Turboextract/npm-packages").call(run_input={
    "searchQueries": [],
    "packages": ["openai", "@anthropic-ai/sdk", "ai", "langchain"],
})
for p in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(p["name"], p["weeklyDownloads"], p["version"])
```

***

### Input

| Field | Default | What it does |
|---|---|---|
| `searchQueries` | – | npm search; up to 250 packages each |
| `packages` | – | Exact package names |
| `includeDetails` | true | License, repo, versions, exact monthly downloads |
| `minWeeklyDownloads` | 0 | Downloads floor |
| `maxResults` | 50 | Total cap per run |

***

### Pricing

**$0.0005 per package delivered.** 1,000 packages cost $0.50.

| Option | 1,000 packages |
|---|---|
| **npm Packages Scraper** | **$0.50** |
| Open-source analytics tools | $100+ a month |

***

### Use cases

- **Adoption tracking**: weekly downloads for your SDK and competitors
- **Ecosystem maps**: every package for `keywords:mcp` with downloads
- **Library choice**: compare candidates by downloads, versions and last publish
- **Maintainer outreach**: active maintainers in a niche
- **Abandonment checks**: popular packages with no publish in two years

***

### Tips

- npm search supports qualifiers like `keywords:llm`, `author:sindresorhus` or `maintainer:name`.
- Weekly downloads cover the last full week. Monthly downloads cover the last 30 days.
- Maintainer emails are not exported, only npm usernames.
- Scoped packages work as names, like `@types/node`.

***

### Pairs well with

- [GitHub Trending Repos](https://apify.com/Turboextract/github-trending-repos): fast-rising repositories
- [Stack Overflow Scraper](https://apify.com/Turboextract/stackoverflow-questions): questions about the same libraries
- [Hugging Face Scraper](https://apify.com/Turboextract/huggingface-models): open AI models and datasets

***

### FAQ

**Do I need an npm account?** No. The actor uses npm's public registry and downloads APIs.

**How accurate are downloads?** They are npm's official counts, which include CI and mirror traffic.

**Does it include private packages?** No, only public ones.

**How fresh is the data?** It is read live on every run.

**Is it legal?** It uses npm's public APIs.

***

### SEO keywords

npm packages scraper, npm downloads API, npm package stats export, JavaScript library downloads, npm search to CSV, npm maintainers list, compare npm packages, open source adoption tracker, npm registry data, devtool market research

***

### Support

- Docs and examples: https://github.com/andersonjames38phd-cpu/npm-packages
- Community Discord: https://discord.gg/8SrXSCpvgj

Built and maintained by [Turboextract](https://apify.com/Turboextract) on the Apify platform.

# Actor input Schema

## `searchQueries` (type: `array`):

Search npm, like web scraper, react table or keywords:llm. Up to 250 packages each.

## `packages` (type: `array`):

Exact package names, like react, axios or @apify/client.

## `includeDetails` (type: `boolean`):

Adds license, repository, homepage, version count, created date and exact monthly downloads.

## `minWeeklyDownloads` (type: `integer`):

Skip packages with fewer downloads last week.

## `maxResults` (type: `integer`):

Stop after this many packages in total.

## Actor input object example

```json
{
  "searchQueries": [
    "web scraper"
  ],
  "includeDetails": true,
  "minWeeklyDownloads": 0,
  "maxResults": 50
}
```

# Actor output Schema

## `results` (type: `string`):

One row per package with downloads, version, maintainers and links.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "searchQueries": [
        "web scraper"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("turboextract/npm-packages").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "searchQueries": ["web scraper"] }

# Run the Actor and wait for it to finish
run = client.actor("turboextract/npm-packages").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "searchQueries": [
    "web scraper"
  ]
}' |
apify call turboextract/npm-packages --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,turboextract/npm-packages"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/6v5CqIRBT8n9uuAiN/builds/rngzjwbyfZN99ZXp7/openapi.json
