How to bypass the maximum image input limit for the Azure OpenAI API

85795786 100 Reputation points
2025-11-12T02:50:44.7533333+00:00

Please note that this text has been translated from Japanese to English using a translation tool, so there may be unnatural expressions or contextual errors. We appreciate your understanding.

Inquiry Topic

I am looking for a way to bypass the image limit mentioned in the documentation (https://learn.microsoft.com/en-us/azure/ai-foundry/openai/quotas-limits?tabs=REST#quotas-and-limits-reference) under the section titled "GPT-4o and GPT-4.1 maximum images per request (number of images in the messages array or conversation history)," as I am running into this restriction.

Details

I am currently inputting 10 images and a PDF into the Azure OpenAI API, all encoded in Base64. Since the PDF has 49 pages, it seems to be hitting the image count limit.

I would like to know how to structure my request to avoid this restriction.

Below is the original text in Japanese.

・お伺いしたい内容

ドキュメント(https://learn.microsoft.com/en-us/azure/ai-foundry/openai/quotas-limits?tabs=REST#quotas-and-limits-reference)の「GPT-4o and GPT-4.1 maximum images per request (number of images in the messages array or conversation history)」の項目にある画像の枚数制限に引っかかってしまうため、回避する方法を探しています。

・詳細

AzureOpenAIのAPIへ10枚の画像とPDFをBase64でエンコードして入力しています。PDFのページ数が49ページあるため、画像枚数の制限に引っかかっているようです。

この制限にかからないようにする方法を知りたいです。

Azure OpenAI Service
Azure OpenAI Service
An Azure service that provides access to OpenAI’s GPT-3 models with enterprise capabilities.
0 comments No comments
{count} votes

Answer accepted by question author
  1. Manas Mohanty 13,340 Reputation points Moderator
    2025-11-13T15:43:04.2+00:00

    Hi 85795786

    100 pages, 32 MB max file limit is for Text based pdfs.

    10 pages is max page limit for image-based pdf. You can put 10 pages in 1 pdf.

    Please chunk larger pdfs to smaller pdf if it is crossing the page limit

    Please chain the API calls separately to parse the text-based content pdf and image-based content pdfs to avoid page limit.

    All generated insights can be appended to a Summary list before generating a final summary.

    Product group already acknowledged the gap and working to increase the image limit in pdfs.

    Reference - https://learn.microsoft.com/en-us/answers/questions/5533291/azure-openai-why-am-i-getting-too-many-images-in-r?comment=question&translated=false

    Please let us know if you have followed up queries on it.

    Thank you.

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.