How Many Tokens in a Screenshot: GPT, Claude, and Gemini Count Images Differently
OpenAI
Anthropic
Google/DeepMind
Using a 1920x1080 test screenshot, the article calculates the visual token cost for image input in GPT-5.5, Claude Opus 4.8, and Gemini 3.1 Pro Preview based on developer documentation. It explains how each model processes images, compares token counts, and offers practical advice on preparing screenshots for analysis.
The article examines how different AI models count visual tokens for image inputs, using a 1920x1080 screenshot as an example. GPT-5.5 uses a 32x32 pixel grid, resulting in 2040 visual tokens. Claude Opus 4.8 uses a 28x28 pixel grid, giving 2691 tokens. Gemini 3.1 Pro Preview uses approximate budgets via media_resolution, with high mode allocating up to 1120 tokens. The piece also discusses the effects of cropping: a 960x540 fragment reduces token count to 510 for GPT and 700 for Claude, though Gemini's budget remains the same. It advises preparing screenshots by removing unnecessary elements and optionally sending both a full view and a zoomed fragment. For image generation, the article notes that GPT Image 2 produced a 1024x1024 image using 4160 tokens, costing 187,200 CAPS, while Nano Banana 2 cost 67,200 CAPS for similar generation.
- Abbreviations
- CAPS = Custom API Payment System — внутренняя валюта сервиса BotHub
- OCR = Optical Character Recognition — оптическое распознавание символов
- PDF = Portable Document Format — переносимый формат документов
- API = Application Programming Interface — интерфейс программирования приложений
- JPEG = Joint Photographic Experts Group — формат сжатия изображений
- PNG = Portable Network Graphics — формат растровой графики
Source: Habr — хаб ML —
original
