
Elon Musk’s artificial intelligence company, xAI has introduced a major new feature for its Grok AI model, allowing it to handle and analyze files through its API. The update allows developers to upload different kinds of documents directly to Grok so the model can read their contents and answer questions about them. This means that instead of depending only on text-based prompts, users can now interact with Grok by providing files like PDFs, CSVs, JSON data, and code scripts, and receive insights, summaries, or computations based on the uploaded material.
The new Files API is available for Grok-4 and Grok-4 Fast. Users can attach several files in the same conversation, allowing the AI to reference and reason across them. For example, a user could upload a financial statement in PDF form alongside a CSV of recent sales data, then ask Grok to find trends or generate comparisons between them. Even the new capability goes beyond reading and summarizing files. xAI has also enabled Python code execution within the Grok environment, allowing the model to perform computations or data visualisations directly from uploaded datasets. If a developer uploads a CSV file containing sales records, Grok can write and run code to calculate averages, generate charts, or identify irregularities (all within the same chat).
In terms of pricing, the AI firm has introduced a separate billing system for the use of this feature. The tool invocations (which include file uploads and related analysis actions) are priced at $10 per 1,000 uses, in addition to the usual token-based API costs. This pricing model clearly positions the Files API as a premium capability aimed at developers, analysts, and enterprises.
This comes as Grok faces intense competition from prominent rival models like OpenAI’s GPT series and Anthropic’s Claude, both of which already offer similar file-handling capabilities. While the Files API is officially described as generally available, the company notes that it currently works only with specific Grok versions and that certain file size and quantity limits still apply.
But despite all these advancements, the Grok model and several of its features are still not free from controversies and challenges. For example, in August 2025, reports surfaced that a glitch in the sharing feature exposed around 370,000 private Grok AI conversations online. Earlier, the company came under fire for the ‘spicy mode’ in Grok Imagine (the text-to-video tool) and faced criticism over explicit AI companion interactions.