Skip to main content

HTTP 413 Content Too Large

The request body exceeds the server's size limit.

4xx · Client error✗ not retryable — fix the request instead

In AI APIs specifically

Hit by oversized image payloads, giant tool results, or batch files over the per-file cap. Distinct from context-window overflow, which is usually a 400.

Fix checklist

  • Check the provider's documented payload limits.
  • Resize/compress images before base64-encoding.
  • Split batch files into smaller chunks.

Spec: RFC reference