Tools
DOCX to JSON API
Submit any Word document. Get back text content as searchable chunks, metadata, author, title, and a thumbnail as structured JSON.
Try it below:
Turn Word documents into structured JSON
Upload a DOCX file or submit a URL, get structured JSON back.
What is Exabase's DOCX to JSON API?
Submit a DOCX file to the Exabase Extract API and get structured JSON back. The response includes the document title, author, page count, creation date, MIME type, file size, a CDN-hosted thumbnail, a rendered PDF version, and the full text content split into searchable chunks. The API handles the parsing. No python-docx, no mammoth.js, no LibreOffice on your end.
This is the same POST /v2/extract endpoint used for all content types. When the API recognises a Word document, it extracts the text, generates a rendered version, and returns structured output. For Word documents containing invoices, contracts, or resumes, the API also detects the document type and populates extraction.document.structured with type-specific fields, just as it does for PDFs.
What you get back
The response includes the document metadata (title, author, page count, creation date), a CDN-hosted thumbnail, a rendered PDF version, and the full text as searchable chunks. Each chunk has a sequence number, the extracted text, and a page number. For recognised document types, structured fields appear alongside the metadata. The API reference has the complete response schema.
One multi-modal API
The same POST /v2/extract endpoint handles every content type Exabase supports. For DOCX files, it returns text chunks with page numbers and document metadata. For PDFs, it does the same with structured field extraction for recognised types. For EPUBs, it returns book metadata and text chunks. For audio and video, it generates transcripts with timestamps. For images, it runs OCR. For web pages, it renders JavaScript and extracts the content.
The submission flow is identical across all types: one endpoint, one SDK method, one webhook configuration. You learn the pattern once and use it for everything. The Extract docs cover each content type in detail.
What you can build with it
The structured chunks are the same format used across the Exabase platform. Feed them into a RAG pipeline so your agent can reference and cite specific passages. Build a document management system where uploaded Word files are parsed and indexed automatically. Process internal reports, proposals, and memos and make them searchable across your organisation.
Store extracted documents as Resources in a Base and the content becomes searchable through Deep Search at the paragraph level. Workers can process new uploads on a schedule, keeping your knowledge base current without manual work.
Beyond extraction
The Extract API returns more than text chunks. You get a CDN-hosted thumbnail, a rendered PDF version, and standard document metadata. Store the output as a Resource and it's searchable through Deep Search immediately. Extract key details into Memory so your agent retains what it read between sessions.
How do I use it?
Get your API key
Free, no credit card:
Sign up at exabase.io and copy your API key from the dashboard.
Submit a Word document
Using the SDK (Node.js):
Get the result
Poll the job until state reaches completed, or skip polling entirely with webhooks.
One API call. No python-docx, no mammoth.js, no LibreOffice.
Why Exabase
Comparisons
Works with other Exabase features
Use cases
FAQs
What is Exabase?
Exabase is infrastructure for AI agents. It gives your agents memory, versioned file storage, AI deep search, and context automation through a set of APIs. Store what your agent learns, search inside any content type, and keep knowledge bases current automatically. Built for production use. Give your agent precise context and cut your token spend by up to 81%.
Who uses Exabase?
Developers and teams building AI agents, copilots, and RAG applications. If your agent needs to remember things between sessions, store and retrieve files, search across documents and media, or stay up to date without manual maintenance, Exabase handles that infrastructure so you can focus on your product.
Does it handle .doc files (old Word format)?
The API is optimised for .docx (Office Open XML). Older .doc files (binary format) may be supported but .docx is recommended for best results.
Does it extract tables and images from the document?
The API extracts text content, including text from tables. Embedded images are not extracted as separate files, but the rendered PDF preserves the full visual layout.
Does it detect document types (invoices, contracts, resumes)?
Yes. If the Word document contains an invoice, contract, or resume, the API detects the type and populates extraction.document.structured with type-specific fields, just as it does for PDFs.
Can I submit a URL instead of uploading a file?
Yes. Pass a url field in the request body pointing to a publicly accessible DOCX file.
Do I have to poll for results?
No. You can configure a webhook URL and Exabase will POST the full result to your server when processing completes. The webhooks guide covers setup.
What happens if extraction fails?
The job state moves to failed. Call the reprocess endpoint to retry without re-uploading.
How long are files retained?
Stored files are retained for 1 day from job creation, then permanently deleted. Download or copy anything you need before the retention window expires.
Is there an SDK?
Yes. The @exabase/sdk package for Node.js/TypeScript handles file streaming, job polling, and chunk retrieval. Install with npm install @exabase/sdk. Or call the REST API directly from any language.
What other file types does Extract recognise?
PDFs, EPUBs, PPTX, images (with OCR), audio (with transcription), video (with transcription), and web pages. The same POST /v2/extract endpoint handles all of them.