Skip to main content

Extract Text from Image

ImageExtract Text from Image

The Extract Text from Image API extracts text from an image using OCR. You send the image as Base64 (docContent), docName, and optionally async. The API returns JSON with the extracted text. Use the tester below to try it; more details are in the sections that follow.

Try the Extract Text from Image API

:::note Quick reference Endpoint: POST /api/v2/ImageExtractText · Required: api-key, docContent, docName :::

:::info Try it live Use the form below to send your API key and image (Base64). The response is JSON with extracted text. No code required—fill the fields and click Send request. :::

Loading API Tester...

Overview, parameters, and use cases

What is Extract Text from Image?

This endpoint uses OCR (Optical Character Recognition) to extract text from an image. You provide the image (Base64), docName, and optionally async. The API returns JSON with the extracted text. Works best with clear, high-resolution images, standard fonts, good contrast, and horizontally oriented text.

Key features

  • OCR – Optical character recognition for images (JPG, PNG).
  • Single request – Send docContent, docName; no extra configuration.
  • Async – Use async for large images.

:::tip Best for Use when you need to read text from screenshots, scans, or photos. For PDF text extraction see Extract Text by Expression or other Extract APIs. :::

Prerequisites

Before using this endpoint, make sure you have:

  • A valid PDF4me API key (Get your API Key)
  • An image file (JPG, PNG) containing text in Base64 format

Response Format

The API returns a JSON response containing extracted text content from the image.

Get Help