> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://contentful.com/developers/docs/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://contentful.com/developers/docs/_mcp/server.

Links are a powerful way to model relationships between content entries and assets. You can learn more about links in our [concept guide](/concepts/links).

## Retrieval of linked items

When you have related content (e.g. entries with links to image assets) it's possible to include both search results and related data in a single request. Using the `include` parameter, you can specify the number of levels to resolve.

The maximum number of levels is **10**. The API will throw a `BadRequestError` for higher values or values other than an integer. The default number, if the parameter is not specified, is 1. To omit linked items, specify `include` as 0.

If the standard `items` array has not already retrieved the linked entries, they will be in the `includes.Entry` array. Linked assets are inside the `includes.Asset` array.

**Note**: The `include` parameter resolves links between entries and assets within a space. Links between content types within a space are not included in the response.

**Note**: The `include` parameter is only available for the entry collection endpoint `/spaces/{space_id}/environments/{environment_id}/entries`.

To query entries with linked items, use the [Get all entries of a Space](/references/content-delivery-api/entries/get-all-entries) endpoint, see example:

```
/spaces/yadj1kx9rmg0/environments/staging/entries?access_token=fdb4e7a3102747a02ea69ebac5e282b9e44d28fb340f778a4f5e788625a61abe&include=2
```

## Links to a specific item

If you want to retrieve all items linked to a specific entry, the query URL should filter entries on their specific `content_type`, `linking_field` (field to link items) and `entry_id` from the target entry.

To query entries linked to a specific entry, use the [Get all entries of a Space](/references/content-delivery-api/entries/get-all-entries) endpoint, see example:

```
/spaces/yadj1kx9rmg0/environments/staging/entries?access_token=fdb4e7a3102747a02ea69ebac5e282b9e44d28fb340f778a4f5e788625a61abe&include=2&content_type=2PqfXUJwE8qSYKuM0U6w8M&fields.brand.sys.id=4LgMotpNF6W20YKmuemW0a
```