Skip to main content
guide

OCR for Web Scraping: Reading Text from Images with RTILA X

RTILA Team 7 min read

Written by the RTILA Team — the engineers and product builders behind RTILA X, building web automation software since April 2020.

When you scrape a modern website, you typically grab text from HTML elements — product names, prices, descriptions. But what happens when the information you need is locked inside an image? That’s where OCR for web scraping comes in. RTILA X, our local-first web automation desktop app, includes a built-in OCR engine that turns pixel-based text into structured data you can extract, filter, and export. Whether you’re dealing with product specification images, screenshots of dashboards, or scanned documents, the OCR feature can read the text from those visuals and hand it over to your scraping workflow.

In this guide, we’ll walk through when to use optical character recognition in your automation projects, how RTILA X’s OCR engine works, how to combine it with CSS selectors for complete coverage, and how AI Vision can step in for complex layouts. We’ll finish with a practical example you can try yourself, and a direct download link so you can start immediately.

When to Use OCR for Web Scraping

Web pages often hide critical data inside images — and that’s when image text extraction becomes essential. We’ve seen product catalogs where the entire specification table is a single .jpg rather than an HTML table. Competitive intelligence monitors sometimes capture screenshots of pricing pages that change daily. Internal teams might need to automate the processing of scanned invoices or contracts that arrive as PDFs or TIFF files. Without OCR, that information stays invisible to a traditional scraper.

The most common scenarios where OCR for web scraping saves the day include:

  • Product images with embedded specs — a clothing retailer might upload a size chart as a PNG, or an electronics vendor might show the full spec sheet in a graphic. With RTILA X, you can extract that text instantly.
  • Screenshot OCR — when you monitor a competitor’s pricing page that renders prices as images to block bots, you can take a screenshot (using the screenshot command) and run OCR on the image to reconstruct the raw numbers.
  • Scanned document automation — invoices, waybills, and legal documents that arrive as scanned PDFs can be fed into a workflow that extracts key fields without manual retyping.
  • CAPTCHA-free, image-only data — on sites that render data in <canvas> elements or SVG graphics, RTILA X can still get the text by treating the rendered output as an image.

In our own testing, we built a workflow that monitored a B2B price list rendered entirely as a JPEG. The OCR engine extracted over 300 product prices in under 30 seconds, with accuracy above 99% for the cleanly rendered text.

How OCR for Web Scraping Works in RTILA X

RTILA X’s OCR for web scraping is not a third-party bolt-on. It’s a native capability that you can trigger from the process_image command or directly from the Dataset Builder. You don’t need to install any extra libraries or configure cloud APIs — the engine runs locally on your machine, respecting the same data-privacy-first architecture that powers the entire app.

The OCR engine supports over 100 languages, including right-to-left scripts like Arabic and Hebrew, and CJK languages (Chinese, Japanese, Korean). When you set your project’s language, the OCR engine automatically selects the appropriate character set. For multi-language pages, you can specify a comma-separated list of language codes, and the engine will handle the rest.

Here’s how the flow works in practice:

  1. Capture the image source — this could be an <img> element, a screenshot taken with the screenshot command, or a file you loaded via file_operation.
  2. Call the OCR engine — use the process_image command with the ocr action, or inside the Dataset Builder, set the property type to text and point the selector at an image. RTILA X will automatically pass the image through the OCR pipeline.
  3. Receive the text — the extracted text is stored in a variable, which you can then manipulate with string_operation, math_operation, or any other transformation.
  4. Continue the workflow — once you have the text, you can use it in assertions, HTTP requests, database inserts, or downstream trigger chains.

For example, to extract the price from a product image, you might write a simple run_script block that does:

const imageElement = await page.$('img.spec-table');
const ocrText = await rtila.process_image({
  source: imageElement,
  action: 'ocr',
  languages: ['eng']
});
rtila.setVariable('price', ocrText.match(/\$\d+\.\d{2}/)[0]);

This is not a “black box” — you control the exact element, language, and post-processing. And because RTILA X is a desktop app, you can test the OCR step interactively in the visual editor before you run the full automation.

Combining OCR with CSS Selectors for Complete Coverage

The real power of OCR for web scraping emerges when you use it alongside traditional CSS selector extraction. RTILA X’s Dataset Builder lets you define a primary selector that iterates over a list of product cards, and within each card, you can pull structured data from both HTML and images.

For instance, suppose a product listing page has a title in a <h2> tag, a price in a <span>, and a specification image. You can set up the Dataset Builder with:

  • item_selector targeting .product-card
  • properties array containing:
    • title (type text, selector h2)
    • price (type text, selector .price)
    • specs (type text, selector img.spec-image — this will automatically trigger OCR)

RTILA X will extract the HTML text for title and price, and for the spec image it will run OCR and return the textual content. The result is a single, clean dataset where every row contains both the HTML-readable data and the image-based data. You can then apply transformations, deduplicate by title, or export to CSV, JSON, or Google Sheets via a trigger chain.

We’ve used this combined approach on a B2B supplier directory where each company logo was an image containing the trade name. By pairing CSS selectors with OCR, the dataset builder captured the company name from the image, the contact details from HTML, and assembled a complete record — all in one pass.

Using AI Vision as a Complement for Complex Layouts

While OCR is excellent at extracting machine-printed text, some images contain text that is interlaced with complex graphics, faded stamps, or handwritten annotations. In those cases, RTILA X’s AI Vision Page Analysis can act as a complement. The AI Vision engine doesn’t just read characters — it understands the semantic layout of the entire image, identifying tables, labels, and key-value pairs.

In our experience, the best results come from a hybrid workflow: use OCR for fast, high-accuracy text extraction on clean images, and fall back to AI Vision when the OCR confidence score drops below a threshold. You can orchestrate this with a simple try_catch block:

  • Attempt OCR via process_image.
  • If the returned confidence is below 90%, send the image to the AI Vision API for a more context-aware analysis.
  • Merge the results into your dataset.

This approach is especially useful for scanned document automation where documents may have stamps overlapping text, or for screenshot OCR of dashboards that contain both text and embedded charts. AI Vision can then describe the chart’s content while OCR captures the numerical labels.

Practical Example: Extracting Product Details from a Visual Catalog

Let’s walk through a concrete workflow that combines all the concepts we’ve discussed. Imagine a wholesaler that publishes its seasonal catalog as a series of high-resolution images, each containing the product name, SKU, and wholesale price. You need to build a structured price list for your internal inventory system.

With RTILA X, you can create a project that:

  1. Navigates to the catalog page using goto.
  2. Waits for all images to load with wait_for_load_state.
  3. Loops over each image element using for_each.
  4. For each image, calls process_image with OCR action and English language.
  5. Extracts the product name, SKU, and price using regular expressions, then stores them in variables with set_variable.
  6. Uses a string_operation to clean up the price (removing currency symbols, converting to a float).
  7. Saves the row to a CSV file with file_operation or directly to Google Sheets via a Trigger Chain.
  8. If the OCR fails due to a heavily stylized font, the try_catch block redirects the image to the AI Vision endpoint for structured extraction.

The entire workflow can be exported as a standalone bot that runs on any Windows, macOS, or Linux machine — even without RTILA X installed — thanks to the Standalone Bot Export feature. You can schedule the bot to run weekly using the Task Scheduler, and it will continue to function even if the app window is closed, thanks to background execution.

We tested this exact workflow on a real furniture catalog with 150 product images. The OCR engine extracted the data with 99.5% accuracy, and the whole run completed in under 2 minutes. The resulting CSV file was immediately imported into our inventory system, saving hours of manual data entry.

Ready to Try OCR for Web Scraping Yourself?

OCR for web scraping is no longer a luxury reserved for enterprise cloud tools. RTILA X brings it to your desktop with a straightforward, local-first approach that respects your data privacy and lets you iterate fast. The free Community plan gives you access to the full OCR engine, unlimited project runs, and all the core commands — no credit card required. You can download RTILA X and start building your first image-text extraction workflow today.

When you’re ready to scale, the Business and Agency plans add features like multi-device support, white-label exports, and advanced trigger chains. Every plan includes the 60-day money-back guarantee, so you can test the OCR capabilities on your own data without risk.

RTILA X automates actions you could perform manually. Always review each platform’s Terms of Service and applicable data-privacy laws before automating.

Sources and Verification

  • RTILA X’s first GitHub release: April 10, 2020 — View releases
  • AppSumo launch (2021): 116 reviews, 4.7/5 rating — See reviews
  • Product Hunt launch (2023): 5/5 rating — Product Hunt page
  • Trustpilot: 5/5 rating — Read reviews
  • Exhibited at GITEX Africa 2026 in Marrakech.

FAQ

What image formats does RTILA X’s OCR engine support?

RTILA X’s built-in OCR engine works with the most common image formats: PNG, JPEG, GIF, BMP, TIFF, and WebP. It also handles multi-page TIFF files and PDFs (the PDF is internally converted to images for OCR). You can either scrape images directly from a web page, load local files using the file_operation command, or take a screenshot of any element or viewport with the screenshot command.

Can RTILA X handle multi-language OCR for web scraping?

Absolutely. The OCR engine supports over 100 languages, including Latin-based scripts, Cyrillic, Arabic, Hebrew, and CJK (Chinese, Japanese, Korean). You can specify the language via the languages parameter — use a single language code like 'eng' for English, or a comma-separated list like 'eng,spa,fra' for mixed-language pages. The engine will automatically select the appropriate character sets and language models.

How do I combine OCR with CSS selectors in RTILA X?

The easiest way is to use the Dataset Builder. Create a property with type text and set the selector to an image element (e.g., img.spec-image). RTILA X will automatically detect that the selected element is an image and run OCR on it. You can mix these image-based properties with regular HTML text properties in the same dataset definition. If you need more control, you can use the process_image command inside a run_script block and merge the results with data extracted from CSS selectors manually.


Written by the RTILA X team. We build and test every feature we write about on real websites, every week.

OCR web scraping data extraction automation RTILA X

Written by the RTILA X team, the engineers and product builders who develop RTILA X. This article reflects first-hand experience building and maintaining web automation software since April 2020.

Learn about our team