---
title: "Search for words near each other in titles"
description: "Find articles where keywords appear close together using proximity search"
source: https://apitube.io/cookbook/search-for-words-near-each-other-in-titles
---

#### Input parameters

| Parameter | Description                                    | Type    | Default | Required |
|:----------|:-----------------------------------------------|:--------|:--------|:---------|
| title     | Proximity search using ~N syntax (e.g., "Apple iPhone"~5). | string  |         | Yes      |
| api_key   | Your API key.                                  | string  |         | Yes      |
| per_page  | Maximum number of articles to retrieve.       | integer | 20      | No       |

#### Workflow examples

##### Request to get news articles where words appear near each other:

```shell
curl -X GET "https://api.apitube.io/v1/news/everything?title=\"Apple iPhone\"~5&api_key=YOUR_API_KEY"
```

##### Request for company mentions with context:

```shell
curl -X GET "https://api.apitube.io/v1/news/everything?title=\"Tesla earnings\"~3&api_key=YOUR_API_KEY"
```

##### Request for related terms in close proximity:

```shell
curl -X GET "https://api.apitube.io/v1/news/everything?title=\"stock market\"~3&api_key=YOUR_API_KEY"
```

---

#### Related Examples

- [Search for exact phrases in titles](/cookbook/search-for-exact-phrases-in-article-titles)
- [Get articles with specific title](/cookbook/get-articles-with-specific-title)
- [Get news by title with exclusion](/cookbook/get-news-by-title-with-exclusion)
- [Get latest news about $TRUMP meme coin](/cookbook/get-latest-news-about-trump-meme-coin)
- [Get latest news about DeepSeek AI](/cookbook/get-latest-news-about-deepseek-ai)

