Image to Text: How to Extract Text From An Image
Tags: ai, api, dataextraction, imagetotext
Published: 2023-05-05 15:37:01

*Extracting text from an image has become easier thanks to the advancements in OCR (Optical Character Recognition) technology.*

‍

## **What is OCR technology?**

OCR, also known as Optical Character Recognition, is a process that involves extracting text from images, such as scanned documents or photographs.

‍
![General OCR result on Eden AI](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kmbftgihvyshuq7hnske.jpg)


OCR technology identifies the patterns of characters and symbols from an image, then translates  them into machine-readable text. This process is complex, and the accuracy of OCR depends on various factors such as the quality of the image, font style, size, and language.

Eden AI is a platform that aggregates several OCR models from the best providers and allows users to choose the best one for their data. By aggregating different OCR models, Eden AI offers a more comprehensive approach to text extraction, ensuring higher accuracy rates and lower error rates.

‍

## **How to extract text from images?**

One of the most significant advantages of using Eden AI is that it offers OCR models tailored to specific types of documents, such as invoices, receipts, ID documents, and tables. These OCR models are specifically designed to extract data from their respective document types accurately.

Here's how to extract text from an image using OCR and Eden AI:

‍

### **Step 1: Get your API key**

To perform OCR, you’ll only need to create an account on Eden AI for free. Then, you will be able to get your API key directly from the homepage.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/khbd9rki8ipb3cfemoua.png)

**[Get your API key for FREE](https://app.edenai.run/user/register?referral=how-to-extract-text-from-image)**

### **Step 2: Pick your OCR model**

Choose the OCR model that is best suited for your image type. For instance, if you are uploading an invoice, choose the OCR model designed for invoices:

![https://uploads-ssl.webflow.com/61e7d259b7746e3f63f0b6be/6453c3ba9cbe1e25091a4596_pick%20your%20OCR%20model.png](https://uploads-ssl.webflow.com/61e7d259b7746e3f63f0b6be/6453c3ba9cbe1e25091a4596_pick%20your%20OCR%20model.png)

‍

### **Step 3: Live test the different providers available**

Test the different providers available with your own images and documents:

![https://uploads-ssl.webflow.com/61e7d259b7746e3f63f0b6be/6454f90e21a1aae08185ca61_live_test_different_providers_available_on_eden_ai%20(2)%20(1).webp](https://uploads-ssl.webflow.com/61e7d259b7746e3f63f0b6be/6454f90e21a1aae08185ca61_live_test_different_providers_available_on_eden_ai%20(2)%20(1).webp)

‍

### **Step 4: Start using OCR API**

Use the OCR API by specifying the right provider in the parameters or use one of our ready-to-use plugins:

![https://uploads-ssl.webflow.com/61e7d259b7746e3f63f0b6be/6454f61d685b867b4aaa6417_live_testing_on_eden_ai_app%20(1).webp](https://uploads-ssl.webflow.com/61e7d259b7746e3f63f0b6be/6454f61d685b867b4aaa6417_live_testing_on_eden_ai_app%20(1).webp)

‍

### **Step 5: Set up your account for more API calls**

We offer $10 free credits to start with. Buy additional credits if needed:

![https://uploads-ssl.webflow.com/61e7d259b7746e3f63f0b6be/6454f62f4b305af3612f2b2c_billing_eden_ai%20(1).webp](https://uploads-ssl.webflow.com/61e7d259b7746e3f63f0b6be/6454f62f4b305af3612f2b2c_billing_eden_ai%20(1).webp)

‍

## **Benefits of using OCR on Eden AI**

Extracting text from an image using OCR and Eden AI is a simple process that offers high accuracy rates and lower error rates.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ki9vla6oclgr1koybn7p.gif)


### **Save time and cost**

We offer a unified API for all providers: simple and standard to use, with a quick switch between providers and access to the specific features of each provider.

‍

### **Easy to integrate**

The JSON output format is the same for all suppliers thanks to Eden AI's standardization work. The response elements are also standardized thanks to Eden AI's powerful matching algorithms.

‍

### **Customization**

With Eden AI you have the possibility to integrate a third-party platform: we can quickly develop connectors. To go further and customize your OCR request with specific parameters, check out our [documentation](https://docs.edenai.co/reference/ocr_ocr_create?referral=how-to-extract-text-from-image).

‍

**[Create your Account on Eden AI](https://app.edenai.run/user/register?referral=how-to-extract-text-from-image)**