Hugging Face Models, Datasets & Spaces Scraper avatar

Hugging Face Models, Datasets & Spaces Scraper

Pricing

from $6.80 / 1,000 results

Go to Apify Store
Hugging Face Models, Datasets & Spaces Scraper

Hugging Face Models, Datasets & Spaces Scraper

Scrape Hugging Face Hub models, datasets and spaces with downloads, all-time downloads, likes, trending score, task, library, license, author, base model and dates. Track trending AI models and prolific authors. Export to JSON, CSV or Excel.

Pricing

from $6.80 / 1,000 results

Rating

0.0

(0)

Developer

Scrapers Lat

Scrapers Lat

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

12 hours ago

Last modified

Share

Hugging Face Models, Datasets & Spaces Scraper

Hugging Face Models, Datasets & Spaces Scraper

Here is one real result, with every field the actor returns (model card text trimmed for length, kept real):

{
"id": "google-bert/bert-base-uncased",
"url": "https://huggingface.co/google-bert/bert-base-uncased",
"type": "model",
"modelName": "bert-base-uncased",
"author": "google-bert",
"pipelineTag": "fill-mask",
"library": "transformers",
"downloads": 115858176,
"downloadsAllTime": 3175496998,
"likes": 2732,
"trendingScore": 4,
"gated": false,
"license": "apache-2.0",
"baseModel": null,
"numParameters": 110106428,
"parametersByPrecision": { "F32": 110106428 },
"languages": ["en"],
"revision": "86b5e0934494bd15c9632b12f734a8a67f723594",
"inferenceProviders": [
{ "provider": "hf-inference", "status": "live", "task": "fill-mask", "contextLength": null, "priceInput": null, "priceOutput": null }
],
"benchmarks": null,
"createdAt": "2022-03-02T23:29:04.000Z",
"lastModified": "2024-02-19T11:06:12.000Z",
"tags": ["transformers", "pytorch", "tf", "jax", "rust", "coreml", "onnx", "safetensors", "bert", "fill-mask", "exbert", "en", "dataset:bookcorpus", "dataset:wikipedia", "arxiv:1810.04805", "license:apache-2.0", "endpoints_compatible", "deploy:sagemaker", "deploy:azure", "region:us"],
"source": "Hugging Face Hub",
"observedAt": "2026-08-14T08:31:54.087Z",
"modelCard": "# BERT base model (uncased) Pretrained model on English language using a masked language modeling (MLM) objective. It was introduced in [this paper](https://arxiv.org/abs/1810.04805) and first released in [this repository](https://github.com/google-research/bert). This model is uncased ... (trimmed; full card is 10094 characters when the model-card add-on is on)",
"aiSummary": "The google-bert/bert-base-uncased model is a pretrained transformer model designed for masked language modeling and next sentence prediction tasks in English. It learns bidirectional representations of text, making it suitable for various downstream tasks like sequence classification and token classification. However, it is not intended for text generation tasks and may produce biased predictions due to the nature of its training data.",
"aiTags": ["task: fill-mask", "domain: natural language processing", "modality: text", "architecture: transformers", "language: English", "use-case: masked language modeling", "use-case: next sentence prediction", "use-case: sequence classification", "use-case: token classification", "use-case: question answering"],
"aiUseCases": ["Predicting masked words in sentences", "Determining if two sentences follow each other", "Fine-tuning for text classification tasks", "Extracting features for downstream NLP tasks", "Using in conversational AI applications"]
}

The most complete Hugging Face Hub scraper available. It returns every field the Hub catalog exposes for models, datasets and spaces, plus derived fields (parameter counts, base model, cleaned languages and tags) and optional AI enrichment (model card text, plain-English summary, tags and use-cases), and gives you four filters to target exactly the items you need.

📥 Input · 📤 Output · 💰 Pricing · ▶️ Examples

Apify Coverage Output Billing

Table of contents

What it does

The actor queries the public Hugging Face Hub catalog for models, datasets or spaces, applies the filters you pass as input, paginates through the matching items and writes one normalized record per item to the run's dataset. It reads only data that is publicly available on the Hub (no account or token required). Numbers are coerced to real numbers or null, licenses and base models are parsed out of the raw tag list, languages are de-duplicated, and inference providers and benchmark results are flattened into compact arrays so you can sort and filter without extra parsing.

Optional paid add-ons fetch each item's README model card text and use AI to produce a plain-English summary, descriptive tags and concrete use-cases. Add-ons are off by default and are disabled for free Apify plans.

Quickstart

Open the actor, paste this into the input, and press Run. It returns the top 3 models matching bert by 30-day downloads, with the model card and AI enrichment on.

{
"type": "models",
"searchQuery": "bert",
"sortBy": "downloads",
"maxModels": 3,
"withModelCard": true,
"withSummary": true,
"withTags": true
}

Leave searchQuery empty to pull the global top items for your chosen type and sortBy. Every input field is optional; with an empty input the actor returns the top models by 30-day downloads (default maxModels is 30, capped at 10 on free plans).

Input reference

FieldTypeRequiredDefaultDescription
maxModelsintegerno30Maximum number of items to collect. Free Apify plans are capped at 10 per run.
typeenumnomodelsWhat to scrape: models, datasets, or spaces.
searchQuerystringno(empty)Keep only items whose name matches this text, for example llama, whisper, stable-diffusion. Empty returns the global top items by sortBy.
pipelineTagstringno(empty)Models only. Restrict to one task, for example text-generation, text-to-image, automatic-speech-recognition, text-classification.
sortByenumnodownloadsOrder results by downloads (30-day), likes, trending, or modified (most recently modified).
withModelCardbooleannofalsePaid add-on. Download each item's README model card and add its plain-text body (modelCard). Charged per card fetched. Paid plans only.
withSummarybooleannofalsePaid add-on. AI plain-English summary of each item (aiSummary) from its model card. Charged per item summarised. Paid plans only.
withTagsbooleannofalsePaid add-on. AI descriptive tags and use-cases (aiTags, aiUseCases) from the model card. Charged per item processed. Paid plans only.

Output reference

One dataset item per model, dataset or space. Types: string, integer, boolean, string[], object, object[], or null when the source value is absent.

FieldTypeDescription
idstringFull Hub ID, for example google-bert/bert-base-uncased.
urlstringCanonical Hugging Face URL for the item.
typestringmodel, dataset, or space.
modelNamestringItem name without the author prefix.
authorstringAuthor or organization that owns the item.
pipelineTagstringTask tag (models), task category (datasets), or null (spaces).
librarystringLibrary (models), SDK (spaces), or null.
downloadsinteger30-day downloads, or null.
downloadsAllTimeintegerAll-time downloads, or null.
likesintegerNumber of likes.
trendingScoreintegerHub trending score.
gatedbooleantrue if access is gated, false if open, or null.
licensestringLicense parsed from tags, for example apache-2.0.
baseModelstringBase model path parsed from tags (models), else null.
numParametersintegerTotal parameter count from safetensors metadata (models), else null.
parametersByPrecisionobjectParameter counts per precision, for example { "F32": 110106428 }, else null.
languagesstring[]Cleaned language codes from the card, else null.
revisionstringCommit SHA of the current revision.
inferenceProvidersobject[]Serving providers: provider, status, task, contextLength, priceInput, priceOutput.
benchmarksobject[]Eval results: dataset, task, value, date, verified.
descriptionstringDataset description (datasets only), truncated to 1000 chars.
createdAtstringISO timestamp the item was created.
lastModifiedstringISO timestamp the item was last modified.
tagsstring[]Full raw tag list from the Hub.
sourcestringAlways Hugging Face Hub.
observedAtstringISO 8601 timestamp of when the record was collected.
modelCardstringPlain-text model card body (paid add-on withModelCard), else null.
aiSummarystringAI plain-English summary (paid add-on withSummary), else null.
aiTagsstring[]AI descriptive tags (paid add-on withTags), else null.
aiUseCasesstring[]AI concrete use-cases (paid add-on withTags), else null.
errorstringPresent only on a failed run: a single item with a populated error field is written instead.

Example output record

Real record from a live run (input {"type":"models","searchQuery":"bert","sortBy":"downloads","maxModels":3,"withModelCard":true,"withSummary":true,"withTags":true}). Model card text trimmed for length, all values real:

{
"id": "google-bert/bert-base-uncased",
"url": "https://huggingface.co/google-bert/bert-base-uncased",
"type": "model",
"modelName": "bert-base-uncased",
"author": "google-bert",
"pipelineTag": "fill-mask",
"library": "transformers",
"downloads": 115858176,
"downloadsAllTime": 3175496998,
"likes": 2732,
"trendingScore": 4,
"gated": false,
"license": "apache-2.0",
"baseModel": null,
"numParameters": 110106428,
"parametersByPrecision": { "F32": 110106428 },
"languages": ["en"],
"revision": "86b5e0934494bd15c9632b12f734a8a67f723594",
"inferenceProviders": [
{ "provider": "hf-inference", "status": "live", "task": "fill-mask", "contextLength": null, "priceInput": null, "priceOutput": null }
],
"benchmarks": null,
"createdAt": "2022-03-02T23:29:04.000Z",
"lastModified": "2024-02-19T11:06:12.000Z",
"tags": ["transformers", "pytorch", "tf", "jax", "safetensors", "bert", "fill-mask", "en", "dataset:bookcorpus", "dataset:wikipedia", "arxiv:1810.04805", "license:apache-2.0", "region:us"],
"source": "Hugging Face Hub",
"observedAt": "2026-08-14T08:31:54.087Z",
"aiSummary": "The google-bert/bert-base-uncased model is a pretrained transformer model designed for masked language modeling and next sentence prediction tasks in English. It learns bidirectional representations of text, making it suitable for various downstream tasks like sequence classification and token classification. However, it is not intended for text generation tasks and may produce biased predictions due to the nature of its training data.",
"aiTags": ["task: fill-mask", "domain: natural language processing", "modality: text", "architecture: transformers", "language: English"],
"aiUseCases": ["Predicting masked words in sentences", "Fine-tuning for text classification tasks", "Extracting features for downstream NLP tasks"]
}

Run via API and CLI

Start a run and wait for it to finish, then read the dataset. Replace <TOKEN> with your Apify API token.

Run synchronously and get dataset items in one call:

curl -X POST "https://api.apify.com/v2/acts/scrapers_lat~huggingface-models-scraper/run-sync-get-dataset-items?token=<TOKEN>" \
-H "Content-Type: application/json" \
-d '{"type":"models","searchQuery":"llama","sortBy":"trending","maxModels":25}'

Start a run asynchronously:

curl -X POST "https://api.apify.com/v2/acts/scrapers_lat~huggingface-models-scraper/runs?token=<TOKEN>" \
-H "Content-Type: application/json" \
-d '{"type":"datasets","sortBy":"downloads","maxModels":100}'

Apify CLI:

apify call scrapers_lat/huggingface-models-scraper \
--input '{"type":"models","pipelineTag":"text-to-image","sortBy":"likes","maxModels":50}'

Fetch results

Every run writes to a dataset. Fetch items as JSON, CSV, or Excel by changing format:

# JSON
curl "https://api.apify.com/v2/datasets/<DATASET_ID>/items?token=<TOKEN>&clean=true&format=json"
# CSV
curl "https://api.apify.com/v2/datasets/<DATASET_ID>/items?token=<TOKEN>&clean=true&format=csv"
# Paginate large datasets
curl "https://api.apify.com/v2/datasets/<DATASET_ID>/items?token=<TOKEN>&offset=1000&limit=1000"

<DATASET_ID> is returned as defaultDatasetId in the run object. Use offset and limit to page through large result sets. clean=true drops empty and internal fields.

Billing and limits

  • Pay per result. You are charged per record returned (result event). See the pricing tab for the current per-result price.
  • Paid AI add-ons. withModelCard, withSummary and withTags charge separate per-item events (model_card, ai_summary, ai_tags) only when the enrichment is produced. They are disabled entirely for free plans.
  • No charge on failure. If a run errors, the actor writes a single item with a populated error field and does not charge for it. Empty runs cost nothing.
  • Spend cap respected. Set maxTotalChargeUsd on the run; once reached, the actor stops emitting and charging further billable results.
  • Free Apify plans are capped at 10 records per run and cannot use the AI add-ons. Upgrade for higher maxModels and enrichment.

FAQ and troubleshooting

A run returned 0 records. Why? Your searchQuery or pipelineTag matched nothing. Loosen the filters or clear searchQuery to get the global top items. Zero-result runs are not charged.

Why are the AI fields null? The AI add-ons are off by default, require a paid Apify plan, and need a fetchable model card. If the card is missing or private, modelCard, aiSummary, aiTags and aiUseCases stay null.

Can I scrape datasets and spaces too? Yes. Set type to datasets or spaces. Note that pipelineTag filtering only applies to models, and spaces do not expose download counts.

What does downloads mean versus downloadsAllTime? downloads is the trailing 30-day count that the Hub uses for its download ranking; downloadsAllTime is the cumulative total.

Is this an official Hugging Face tool? No. This actor is independent and has no affiliation with Hugging Face. It reads only data that is publicly available on the Hub. Use it in accordance with the Hugging Face terms of service.

More scrapers at scrapers.lat

Built and maintained by scrapers.lat, where we publish scrapers for US and Latin American public platforms: company registries, government data, finance, e-commerce and more. Browse the catalog or request a custom scraper at scrapers.lat.


Independent tool, not affiliated with Hugging Face. Accesses only publicly available Hugging Face Hub data. Use in accordance with the Hugging Face terms of service.