# payload-too-large

> The body or the batch is larger than allowed. Split it into smaller requests.

`413 Payload Too Large` · `Payload too large` · `type: https://docs.dlogify.com/errors/payload-too-large`

## When it happens

- The decompressed body is larger than the plan's maximum (1 MB by default).
- The batch has more than 1,000 events.
- The batch is too large once encoded.

## How to fix it

Send fewer events per request. The official clients already batch within the limits. See [Limits](https://docs.dlogify.com/send-logs/limits.md).

## Example

```http
HTTP/1.1 413 Payload Too Large
Content-Type: application/problem+json
```

```json
{
  "type": "https://docs.dlogify.com/errors/payload-too-large",
  "title": "Payload too large",
  "status": 413,
  "detail": "A batch may contain at most 1000 events.",
  "instance": "req_01j…"
}
```

Source: https://docs.dlogify.com/errors/payload-too-large
