YouTube Search Results & Entity Type Scraper avatar

YouTube Search Results & Entity Type Scraper

Pricing

from $0.49 / 1,000 results

Go to Apify Store
YouTube Search Results & Entity Type Scraper

YouTube Search Results & Entity Type Scraper

Search YouTube by keyword for videos, Shorts, channels, or playlists, with view counts, duration, and channel details, filterable by upload date, duration, sort order, and region.

Pricing

from $0.49 / 1,000 results

Rating

0.0

(0)

Developer

vexaloom-labs

vexaloom-labs

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

3 days ago

Last modified

Share

Search YouTube without cookies or API keys and get structured rows for videos, Shorts, channels, playlists, and movies. Use YouTube's own filters, follow pagination, and optionally enrich every video with exact views and likes, dates when YouTube exposes them, and categories or tags when available.

What this actor does

  • Five result types: videos, Shorts, channels, playlists, and movies.
  • All-result mode: mix the entity types in YouTube's own order.
  • Server-side filters: upload date, duration, sort order, video features, market, and interface language.
  • Pagination: follow continuation tokens until your limit or YouTube's own ceiling.
  • Optional details: one detail request per video (plus fallback calls when needed) adds exact views and likes, dates when exposed, tags, and the full description.
  • Bulk queries: run several searches in one job.
  • Cookieless: public search data only. No login, no browser, no proxy setup.
  • Omit-empty output: a row only contains values that are actually available.

Input

FieldTypeDefaultDescription
searchQueriesarray—One or more YouTube search terms. Duplicate terms are removed.
maxResultsinteger20Results per query (1-1000). YouTube caps each entity type below 1000.
scrapeAllResultsbooleanfalseFollow pages until YouTube stops returning results, ignoring maxResults.
sortBystringrelevancerelevance or view_count. YouTube no longer supports date or rating sorting.
uploadDatestringanylast_hour, today, this_week, this_month, or this_year.
typestringallvideo, short, channel, playlist, or movie.
durationstringanyshort (under 3 min), medium (3-20 min), or long (over 20 min).
featuresarray[]hd, subtitles, creative_commons, live, 4k, hdr, 360, vr180, 3d. Multiple values are combined.
marketstringUSCountry used for YouTube's search context. 31 markets are available.
languagestringautoInterface language. auto follows the market.
includeVideoDetailsbooleanfalseFetch each video's detail payload for exact views, likes, and duration, plus dates, category, tags, and the full description when YouTube exposes them.
{
"searchQueries": ["web scraping tutorial", "python automation"],
"maxResults": 50,
"type": "video",
"sortBy": "view_count",
"uploadDate": "this_year"
}

Example: Shorts

{
"searchQueries": ["lofi beats"],
"type": "short",
"maxResults": 100
}

Example: channels

{
"searchQueries": ["python tutorials"],
"type": "channel",
"market": "GB"
}

Example: exact video details

{
"searchQueries": ["apify"],
"type": "video",
"maxResults": 20,
"includeVideoDetails": true
}

Output

Every result row has type, position (1-based within the query), searchQuery, and scrapedAt. When YouTube exposes an estimate for the query, estimatedResults is added to each row.

Video and movie rows

FieldExample
videoId"dQw4w9WgXcQ"
title"Never Gonna Give You Up"
url"https://www.youtube.com/watch?v=dQw4w9WgXcQ"
descriptionresult-card snippet
channelName"Rick Astley"
channelId"UCuAXFkgsw1L7..."
channelUrl"https://www.youtube.com/@RickAstley"
channelHandle"@RickAstley" when the byline links to a handle
channelVerifiedtrue when the uploader has a verified badge
viewCountexact integer when the card or details provide one
viewCountText"1.6B views" or "42,963 views" (verbatim)
publishedTimeText"2 years ago"
publishedAtISO 8601 UTC timestamp when a full time is exposed (includeVideoDetails only)
likeCountexact integer (includeVideoDetails only)
category"Science & Technology" when exposed (includeVideoDetails only)
tagsarray of video keywords when exposed (includeVideoDetails only)
fullDescriptionfull description text (includeVideoDetails only)
duration"3:33"
durationSeconds213
thumbnailsarray of {url, width, height}
richThumbnailUrlanimated preview URL when available
badgesresult-card badges such as ["CC", "4K"]
isLivetrue for a live broadcast
isUpcomingtrue for a scheduled premiere or live event
scheduledStartTimeISO 8601 start time for upcoming videos (includeVideoDetails only)
concurrentViewerscurrent viewer count on a live card

Channel rows

FieldExample
channelId"UCxxxxxx"
channelName"Python Programmer"
channelUrl"https://www.youtube.com/@gilesmcmullen"
handle"@gilesmcmullen"
channelHandlesame handle, for consistency with video rows
descriptionsearch-card snippet
subscriberCountapproximate integer from YouTube's rounded label
subscriberCountText"782K subscribers"
videoCount / videoCountTextonly when YouTube shows a video count on the card
thumbnailsarray of avatar images
isVerifiedtrue or false

Playlist and course rows

FieldExample
playlistId"PLxxxxxxx"
title"Python Full Course"
url"https://www.youtube.com/playlist?list=PLxxxxxxx"
channelName"CodeWithHarry"
channelId"UCxxxxxx"
channelUrl"https://www.youtube.com/@CodeWithHarry"
channelHandle"@CodeWithHarry"
videoCount / videoCountText100 / "100 lessons" when available
firstVideoIdfirst video shown on the card
thumbnailsarray of playlist thumbnails

Shorts rows

FieldExample
videoId"abc123"
title"A short example"
url"https://www.youtube.com/shorts/abc123"
viewCountexact integer only when YouTube shows an unabridged count
viewCountText"1.2M views" (verbatim)
thumbnailsvertical thumbnails
badgecard badge when present
isShorttrue

With includeVideoDetails, Shorts also gain channelName, channelId, channelUrl, channelHandle, publishedAt, likeCount, durationSeconds, category, and tags.

Status rows

A typed query with no results produces one status row: recordType: "status", status: "no_results", query, market, resultType, appliedFilters, and resultCount: 0. A failed query produces status: "query_failed" with an error string.

How row limits work

YouTube serves a variable number of results for the same query. There is no fixed ceiling: the same news query returned 343-373 videos, 14-24 Shorts, 601-685 mixed rows, 134-367 channels, 357-461 playlists, and 204 movies on different runs and IPs. Set scrapeAllResults to follow pages until YouTube stops offering results, or use maxResults for a smaller slice. When the requested count is not reached, the status message reports the requested and actual counts and whether the query pool was exhausted, stopped after repeated empty pages, or lost its continuation. It does not claim a fixed ceiling.

Limitations

  • Date and rating sorts are not available. YouTube removed them; the UI suggests only relevance and view count. Saved tasks that still send sortBy: "upload_date" or "rating" are accepted and mapped to relevance with a warning.
  • Subscriber counts are rounded. YouTube only publishes display labels for search results, so subscriberCount is an approximation and subscriberCountText is the verbatim label. Localized labels are parsed, including Japanese チャンネル登録者数 184万人 and Korean 구독자 8.65만명.
  • Some exact fields need a full player response. On datacenter IPs YouTube can return a reduced response. Exact views, likes, and duration normally resolve, but publishedAt can be date-only or absent and category/tags can be omitted. The actor never fills these with zero or a placeholder.
  • Live view counts are a live counter. For an active stream, the detail viewCount follows the current live counter and is not comparable to lifetime views. Use concurrentViewers on the card for the live audience.
  • Shorts can stop early. Repeated empty continuation pages can end a Shorts run before the requested count. The run succeeds and the status message reports the requested and actual counts.
  • No comment counts. Comments are handled by the dedicated YouTube comments actor.
  • Shorts cards are sparse. Without includeVideoDetails, YouTube does not expose channel, date, duration, or exact views on a Shorts card.
  • Movies are YouTube's "Movies" filter. It returns movie-catalog videos; some are full films, some are clips or episodes.
  • Results vary between runs. YouTube personalizes and re-ranks search results over time.
  • Detail fields can be withheld. On some datacenter IPs YouTube returns a limited player response. The actor tries a second player client and the watch-next payload; fields that remain unavailable (viewCount, category, tags, publishedAt) are omitted, never filled with zero or a placeholder.
  • Location and Purchased filters are not offered. They return no cookieless results. Saved tasks that send features: ["location"], ["purchased"], or ["cc"] are accepted: cc maps to subtitles, the other two are ignored with a warning.

FAQ

Do I need cookies or a YouTube API key?

No. The actor reads public search results with no credentials.

Which result types can I request?

Videos, Shorts, channels, playlists, and movies. Leave type empty for mixed results. Saved tasks that send the plural shorts are mapped to the Shorts type.

Why did I get fewer rows than maxResults?

YouTube serves a variable number of rows and there is no fixed ceiling. The status message reports the requested and actual counts and whether the query pool was exhausted or stopped after repeated empty pages. Some Shorts searches can stop early; the same shortfall message applies.

What does includeVideoDetails add?

Exact views, likes, and duration, plus publish date, category, tags, full description, and upcoming/live state when YouTube exposes them. It costs one or more requests per video and makes the run slower.

Why is viewCount missing on some rows?

YouTube shows rounded labels such as 1.6B views on many cards. The actor keeps viewCountText but does not turn a rounded label into a fake exact number. Enable includeVideoDetails for exact views.

Why is a channel's subscriber count approximate?

Search cards only show rounded labels such as 782K subscribers.

Are Shorts supported without details?

Yes. Title, URL, views text, and thumbnails are available. Channel, date, duration, and exact views require includeVideoDetails.

Can I run several searches at once?

Yes. Add them to searchQueries; each query gets its own position sequence and searchQuery value.