Document AI · Amazon

AWS Textract

The boring, reliable AWS document-extraction service — Queries API, expense analysis and key-value tables that just work.

Illustration of cloud storage infrastructure
ParamsTask typeLicenseReleasedAccessPricing
UndisclosedOCR, forms, tables, queries, signaturesProprietary, paid (AWS)2019+ (continuously updated)Managed API (AWS AI Services)Per page, tiered (~$1.50–$15+ / 1K pages by feature, as of Nov 2026)

What it is

AWS Textract is Amazon’s managed document-extraction service, live since 2019 and steadily extended since. It detects text, forms, tables, key-value pairs and signatures in PDFs and images, with specialized APIs for expenses (AnalyzeExpense), IDs (AnalyzeID), and — the crown jewel — Queries, where you ask natural-language questions like “What is the invoice total?” and get back just that value. It is the default when your stack is AWS and your requirement is “work, don’t demo.”

Architecture and how it reads documents

Internals are undisclosed, as with all three cloud giants. Publicly, Textract composes a layout/text backbone with feature-specific heads: AnalyzeDocument (FORMS/TABLES), AnalyzeExpense, AnalyzeID, DetectDocumentText, and the Queries interface, which behaves like a schema-on-demand extraction rather than a fixed schema. Responses are block-structured (PAGE/LINE/WORD/TABLE/CELL/KEY_VALUE_SET/QUERY) with bounding boxes and confidence scores. Architecture hedged as of Nov 2026 — Amazon publishes APIs and accuracy claims, not papers.

Accuracy and table/handwriting handling

On printed forms and tables, Textract is dependable: key-value extraction in the high 80s to 90s on standard templates, and genuinely strong table structure detection out of the box, as of Nov 2026. Handwriting is supported but trails Google Document AI. Signatures on checks and agreements are detected. Dense nested tables and low-quality scans remain error-prone; budget for confidence-threshold filtering and human review loops in regulated flows.

Strengths

  • Queries API. Ask for “invoice total” or “due date” without pre-declaring a schema — the closest thing to document QA without an LLM.
  • AWS-native. Direct event-driven plumbing with S3, Lambda, Step Functions and EventBridge.
  • AnalyzeExpense/AnalyzeID. Mature prebuilt extractors for receipts, invoices and identity docs.
  • Reliability and regions. Every major AWS region, enterprise SLAs, boring in the best way.

Weaknesses

  • No LLM nuance. It extracts fields; it does not reason, summarize or disambiguate.
  • Per-page pricing adds up. Queries and TABLES analysis are notably pricier than plain detect-text at volume.
  • Handwriting trails Google. Fine for legible prints; weak on cursive.
  • BlockJSON ergonomics. Parsing the raw PAGE/LINE/WORD response is tedious without helper code.

Best for / avoid for

Best for: invoice and receipt pipelines inside AWS, event-driven document processing (S3 drop → Lambda → Textract → DynamoDB), compliance document indexing, signature detection, and on-demand field queries over heterogeneous forms.

Avoid for: handwriting-heavy corpora, reasoning-over-document tasks (pair with Bedrock), and Azure/GCP-committed organizations.

Variants

DetectDocumentText (plain OCR), AnalyzeDocument with FORMS and TABLES, AnalyzeExpense, AnalyzeID, Start*Async jobs for multi-page PDFs, and Queries as a feature flag on AnalyzeDocument. Signatures come via the SIGNATURES feature. There is no custom-model training tier like Azure or Google — Queries is the customization story.

Pricing and access

Per page, tiered, as of Nov 2026: DetectDocumentText roughly $1.50 per 1,000 pages; FORMS roughly $50 per 1,000 pages; TABLES roughly $15 per 1,000 pages; Queries roughly $15+ per 1,000 pages (first queries cheaper); AnalyzeExpense roughly $10 per 1,000 pages; AnalyzeID roughly $25 per 1,000 documents. Free tier covers ~1,000 pages/month for three months. Volume pricing kicks in past hundreds of thousands of pages; enterprise agreements available through AWS. Model your real mix — FORMS at scale is the expensive lane.

How to run it

Boto3 example using Queries:

import boto3

client = boto3.client("textract", region_name="us-east-1")
with open("invoice.pdf", "rb") as f:
    data = f.read()

resp = client.analyze_document(
    Document={"Bytes": data},
    FeatureTypes=["QUERIES"],
    QueriesConfig={"Queries": [
        {"Text": "What is the invoice total?", "Alias": "TOTAL"},
        {"Text": "What is the invoice date?",  "Alias": "DATE"},
    ]})
for block in resp["Blocks"]:
    if block["BlockType"] == "QUERY_RESULT":
        print(block.get("Query", {}).get("Alias"), "->", block.get("Text"))

For multi-page PDFs use start_document_analysis with an S3 bucket and poll get_document_analysis, or wire an S3 event trigger. Always filter results by confidence score — below ~80% on high-stakes fields, route to human review instead of trusting blindly.

Benchmarks snapshot

Models-data (as of Nov 2026): “Superior at key-value tables out of the box.” Public benchmarking is limited; commonly cited figures put printed key-value extraction in the ~90% range on standard forms and strong table-structure scores versus peers. All approximate and template-dependent; validate against incumbent on your document samples.

How it stacks up

vs Azure Document Intelligence: Azure wins on prebuilt contract/invoice depth and custom neural training; Textract wins on the Queries API and AWS eventing. Pick your cloud.

vs Google Document AI: Google wins on handwriting and multilingual breadth; Textract wins on zero-schema queries and AWS-native plumbing.

vs open weights (DeepSeek-OCR, dots.ocr): open models win on cost and privacy at scale; Textract wins on SLAs, compliance and no-GPU operations. For governed AWS pipelines, Textract is the least-effort correct answer.

PeaBox fit

Use Textract when the pipeline is already AWS-shaped: S3-ingested invoice dumps, receipt OCR for expense tooling, compliance document indexing. Extracted fields can feed the PeaBox AI Workbench for review and anomaly detection. For one-off or bulk archive digitization, open weights will be cheaper; for SLA-backed AWS-native workflows, nothing else fits as cleanly.

The practitioner’s take

Textract is the grown-up’s OCR: no magic, no model zoo, no GPUs — just reliable extraction with boring APIs and honest confidence scores. Its Queries feature solves the “schema per form” trap that makes document automation brittle, and that alone justifies the premium over plain text detection. Price the FORMS/TABLES lanes carefully, wire confidence thresholds into human review, and it will quietly process a million documents without drama.

More from the atlas