Hirak OCR API

Text Analysis / API Key Intermediate HTTPS
Varies by plan (check documentation)

Overview

Hirak OCR converts images containing text into machine-readable strings, supporting over 100 languages with high accuracy. It accepts image URLs or base64-encoded images and returns the extracted text in JSON format. The API allows unlimited requests, making it practical for batch processing or high-volume workflows.

Beginner Tip

You can submit either a public image URL or a base64-encoded image string — using a URL is simpler for testing since you just need a publicly accessible link to an image file.

Available Data

translated text
source language
target language
confidence score

Example Response

JSON Response
{
  "status": "success",
  "data": {
    "result": "Data from Hirak OCR",
    "description": "Image to text -text recognition- from image more than 100 language, accurate, unlimited requests",
    "timestamp": "2025-01-15T10:00:00Z"
  }
}

Field Reference

text The full text extracted from the image as a single string
confidence OCR confidence score indicating how certain the extraction is (0 to 100)
language Language code used during OCR processing, matching the lang parameter you specified

Implementation Example

Request
const url = "https://ocr.hirak.site/";
// Replace headers or query params with the values required by this API.
const response = await fetch(url, {
  headers: {
  "X-API-Key": "YOUR_API_KEY"
  }
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data);

What Can You Build?

Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.

Common Errors & Troubleshooting

403 Forbidden API key is missing or not passed in the correct header
Include your API key as "x-api-key: YOUR_API_KEY" in the request headers
Empty text in response The image has very low resolution or the text is unclear or stylized
Use clear, high-contrast images (at least 150 DPI) for best OCR results
Incorrect language extraction The "lang" parameter does not match the actual language in the image
Set the lang parameter to the correct ISO 639-1 code matching the image language (e.g., "ar" for Arabic)

Metadata Score Breakdown

Estimated from metadata — endpoint not independently tested

This score is estimated from observable metadata — HTTPS support, authentication model, declared CORS, and documentation reachability — because the API requires authentication or exposes no publicly testable endpoint. The five-signal breakdown is only shown for live-tested APIs.

Metadata estimate · endpoint not independently tested

Technical Specifications

Auth API Key
HTTPS REQUIRED
CORS UNKNOWN
Category Text Analysis
Difficulty Intermediate
Verified: 2026-04-04

Related Tags

Similar APIs

View All →