Search News
Search through millions of articles using full-text search with advanced filtering.
GET/v1/search
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| keywords | string | Required | Search query. Supports boolean operators (AND, OR, NOT) and exact phrases in quotes. |
| language | string | Optional | ISO 639-1 language code (e.g., “en”, “es”, “fr”). |
| country | string | Optional | ISO 3166-1 alpha-2 country code (e.g., “us”, “gb”, “de”). |
| category | string | Optional | News category: technology, business, science, health, sports, entertainment, politics, world. |
| start_date | string | Optional | Start date in ISO 8601 format (e.g., “2025-01-01T00:00:00Z”). |
| end_date | string | Optional | End date in ISO 8601 format. |
| page_size | integer | Optional | Number of results per page (1-200). Default: 10. Maximum depends on your plan. |
| page | integer | Optional | Page number for pagination. Default: 1. |
Example Request
Search for AI newsbash
curl -X GET "https://api.newsapi.dev/v1/search?keywords=artificial+intelligence&language=en&category=technology&page_size=5" \
-H "X-API-Key: your_api_key_here"Example Response
Responsejson
{
"status": "ok",
"total_hits": 3542,
"page": 1,
"page_size": 5,
"articles": [
{
"title": "OpenAI Announces GPT-5 with Enhanced Reasoning",
"description": "The latest model shows significant improvements in mathematical reasoning and code generation capabilities.",
"content": "OpenAI has officially unveiled GPT-5, the next generation of its large language model...",
"url": "https://techcrunch.com/2025/01/15/openai-gpt5",
"image": "https://techcrunch.com/wp-content/uploads/2025/01/gpt5.jpg",
"author": "Sarah Chen",
"source": {
"id": "techcrunch",
"name": "TechCrunch",
"url": "https://techcrunch.com"
},
"category": "technology",
"language": "en",
"country": "us",
"published_at": "2025-01-15T14:30:00Z"
}
]
}Search Tips
- -Use double quotes for exact phrase matching:
"artificial intelligence" - -Use AND to require multiple terms:
AI AND regulations - -Use OR for alternative terms:
Tesla OR SpaceX - -Use NOT to exclude terms:
Apple NOT fruit - -The search covers article titles, descriptions, and content fields.