> This page is for version v2025-04-21.
> For other versions, use one of these documentation indexes:
> - v2026-02-09 (default): https://docs.extend.ai/2026-02-09/llms.txt
> - v2025-04-21: https://docs.extend.ai/2025-04-21/llms.txt
> - v2024-12-23: https://docs.extend.ai/2024-12-23/llms.txt

> ## Documentation Index
> Fetch the complete documentation index at: https://docs.extend.ai/llms.txt
> Use this file to discover all available pages before exploring further.
>
> ## API version
> The current API version is `2026-02-09`, served at the site root (no version prefix in URLs).
> If this page URL contains `/2025-04-21/` or `/2024-12-23/`, you are reading an older API version.
> Prefer the current docs at https://docs.extend.ai/llms.txt unless the user explicitly needs that older version.
> Do not treat older-version pages as the source of truth for new integrations.

# Page Ranges

> Control which pages are processed using pageRanges and fixedPageLimit.

## Page selection

Processors let you restrict which pages of the source document are read and billed.
Use either `pageRanges` **or** `fixedPageLimit`, preferring `pageRanges`, never both.

| Field            | Location          | Type                               | What it does                           |
| ---------------- | ----------------- | ---------------------------------- | -------------------------------------- |
| `pageRanges`     | `advancedOptions` | `{ start: number; end: number }[]` | Fine-grained list of pages to process  |
| `fixedPageLimit` | `advancedOptions` | `number`                           | Shortcut for “use the first *n* pages” |

### pageRanges

```json
"advancedOptions": {
  "pageRanges": [
    { "start": 1,  "end": 3 },
    { "start": 10, "end": 10 }
  ]
}
```

* 1-based, inclusive page numbers
* Ranges can overlap or arrive out of order; the platform merges and sorts them automatically
* Omit the field or pass `[]` to process the full document (subject to global limits)

### fixedPageLimit

```json
"advancedOptions": {
  "fixedPageLimit": 25
}
```

Equivalent to `pageRanges: [{ "start": 1, "end": 25 }]`.
All rules that apply to `pageRanges` also apply to the synthetic range generated from `fixedPageLimit`.

### Chunking behavior

`pageRanges` (or the range derived from `fixedPageLimit`) is applied **before** chunking starts:

1. Selected pages are isolated and renumbered from 1
2. Chunking operates on this renumbered subset
3. Chunk-level options such as `chunkingStrategy` and `pageChunkSize` refer to the virtual page numbers

Example:

```json
"pageRanges": [{ "start": 1, "end": 13 }, { "start": 20, "end": 28}],
"numPagesPerChunk": 5
```

Resulting chunks:

| Chunk | Original pages |
| ----- | -------------- |
| 1     | 1–5            |
| 2     | 6–10           |
| 3     | 11–13, 20-21   |
| 4     | 22-26          |
| 5     | 27-28          |

### Best practices

* Prefer `pageRanges` over `fixedPageLimit`
* Use `pageRanges` for non-contiguous or trailing pages
* Remember that chunking operates on **virtual** page numbers after filtering