youtube.search
Search public YouTube content by keyword or phrase.
Returns matching result cards, estimated result count, and spelling suggestions.
Use filter parameters to apply multiple YouTube search filters:
upload_date: Last hour, Today, This week, This month, This year
content_type: Video, Channel, Playlist, Movie
duration: Under 4 minutes, 4 - 20 minutes, Over 20 minutes
features: Live, 4K, HD, Subtitles/CC, Creative Commons, 360°, VR180, 3D, HDR, Location, Purchased (multiple allowed)
sort_by: Relevance, Upload date, View count, Rating
Filter values are matched case-insensitively. Only one option per group applies except features, which accepts multiple labels.
When a requested filter cannot be applied, the API returns the best-effort results available so far and includes unappliedFilters with the labels that were skipped.
Use cursor with the same query to paginate: pass cursorNext from a prior response. Filter parameters and cursor cannot be combined.
Check didYouMean when the query may be misspelled.
Cost = 20 tokens.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | Search keywords or phrase. | |
| cursor | No | Pagination cursor from cursorNext. | |
| sort_by | No | Sort order. One of: Relevance, Upload date, View count, Rating. | |
| duration | No | Duration filter. One of: Under 4 minutes, 4 - 20 minutes, Over 20 minutes. | |
| features | No | Feature filters. Multiple allowed. Each value must be one of: Live, 4K, HD, Subtitles/CC, Creative Commons, 360°, VR180, 3D, HDR, Location, Purchased. | |
| language | No | Language code for localized results (for example en). | en |
| location | No | Country code for localized results (for example US). | US |
| upload_date | No | Upload date filter. One of: Last hour, Today, This week, This month, This year. | |
| content_type | No | Content type filter. One of: Video, Channel, Playlist, Movie. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| contents | No | Search result entries for the current page. Video entries include a type field and nested video object. | |
| cursorNext | No | Cursor for the next results page, when available. | |
| didYouMean | No | Suggested corrected query when the search may be misspelled. | |
| estimatedResults | No | Approximate total number of matching results. | |
| unappliedFilters | No | Requested filter labels that could not be applied. Present only when at least one filter was skipped. |