Skip to main content
Content updated: 2026-06-09

Gemini Image Understanding

As of 2026-04-08, repeated local testing between Crazyrouter and 4000 port shows:
  • gemini-3.1-pro can reliably read images through inlineData and return text descriptions
  • Using remote image URLs as fileData.fileUri has encountered issues such as fetch failures and abnormal upstream responses across various channels
  • Therefore, the recommended method for image understanding in this document is to use inlineData

Verified Minimal Request

The key response format seen in production:

Request Key Points

  • For image understanding, give priority to inlineData
  • mimeType should match the actual image format, such as image/png or image/jpeg
  • For data, only fill in the Base64 content; do not include the data:image/...;base64, prefix
  • If you only have a remote image URL, do not use it as the preferred main pathway for Gemini image understanding at this time
If you want to work with video understanding, see Gemini Video Understanding. If you want to work with audio understanding, see Gemini Audio Understanding.