
Gemini API: you can now load only the pages or cells the AI needs to read
Redacción IvokaNov 26, 7:30 AM 3 min
Google launched "file slicing" controls in the Gemini API: you choose which pages, sheet ranges or media segments to load, and tokens are billed only for what the model inspects. It also accepts Office and OpenDocument files.
Google announced file slicing controls in the Gemini API. It's a feature aimed at people who build tools, but its effects could reach the apps you use.
What it does, in plain terms
Instead of sending the AI a whole document of hundreds of pages, a developer can specify which pages, which ranges of a spreadsheet or which audio and video segments the model should look at. Google says this keeps context focused on the relevant parts of a file and bills tokens only for the parts Gemini inspects.
Office files
The update also adds native upload of Microsoft Office and OpenDocument files (documents, slides and spreadsheets).
Where it's available
According to Google, it works across all Gemini 4 models and is available today through the API in Google AI Studio and the Gemini platform. Existing file size and page limits still apply to the full uploaded file. Gateway and SDK partners validated the controls before launch.
Why it should matter to you
If you use an app that summarizes contracts, catalogs or reports with Gemini, this feature can help those tools use fewer tokens by reading only what's needed. Savings depend on the file type, the content layers and resolution chosen, and how much of each file is loaded. Partner tests cited by AlphaSignal show, for example, that Vercel measured 14 times fewer tokens when extracting a page's text than when rendering the full PDF, and that LiteLLM cut prompt tokens 67% on a PDF and 33% on a workbook. These figures come from partner workloads and may vary.
Sources

