Google launched file slicing controls in the Gemini API on Nov 23, 2026, in Google AI Studio and the Gemini platform (Google). A developer or an agent uploads a file once and asks for only the pages, spreadsheet cells, media segments and content layers it needs, and tokens are billed only for the parts Gemini inspects.
Launch partners’ own testing, as reported by Google
- fewer tokens for Vercel, skimming a page’s text instead of rendering the whole PDF
- 14x
- fewer prompt tokens for a PDF in LiteLLM’s testing
- 67%
- fewer prompt tokens for a workbook in LiteLLM’s testing
- 33%
What happened
The same launch adds native upload of Microsoft Office and OpenDocument files. A file goes to the Files API once, and its URI can be reused across turns and tool calls, including inside a function response, where an agent names the part of the file it wants. The feature works across all Gemini 4 models, and existing file size and page limits still apply (Google).
The controls by media category (Google):
- Documents and slides (PDF, Office, OpenDocument): a page range, a resolution of low, medium or high, and page text or page images
- Spreadsheets (.xlsx, .xls, .ods): a worksheet tab and cell range, a resolution, and data, formulas or visuals
- Video: a time interval, fps and resolution, and the transcript, frames or audio
- Audio: a time interval
With no options set, documents and slides load as page images that keep their layout, and spreadsheets load values, formulas and sheet names from every tab.
Why it matters
Google says that when an API takes only whole files, agent harnesses end up running LibreOffice, PDF renderers and ffmpeg on the client to cut files down, which uses memory and disk and pushes companies to keep a sandbox for each user. With slicing, the API renders and splits the file on Google’s servers. Google suggests skimming a file as cheap extracted text first, then reading only the pages or frames that matter at high resolution (Google).
The savings figures above come from Vercel and LiteLLM. The post gives no savings measured by Google and no prices beyond billing for the inspected parts.




