Skip to main content
All CollectionsRobotsBuilding robots
How to extract data from iFrames
How to extract data from iFrames

While Browse AI doesn't directly support iFrames, you can extract data by finding and using the iFrame's source URL in most cases.

Nick Simard avatar
Written by Nick Simard
Updated this week

What is an iFrame?

An iFrame (Inline Frame) is an HTML element that embeds another webpage within the current page. Think of it as a window showing content from another website. Many websites use iFrames to display content from external sources, such as maps, videos, or forms.

The challenge with scraping from an iFrame

When training your robot in Browse AI, if you try to capture data from an element inside an iFrame, you'll see this error:

"This element is inside an iFrame. iFrame interactions are not supported in Browse AI recordings yet."

Fortunately, there's a simple workaround that works for most iFrames.

Workaround: Find the direct URL of the iFrame content

Most iFrames display content that has its own direct URL. By accessing this URL, you can train your robot to extract the data without dealing with the iFrame.

Step 1: Find the iFrame source URL

  1. Close your Browse AI recording window

  2. Open the website in a regular Chrome browser

  3. Right-click on the area inside the iFrame where you want to extract data3

  4. Select Inspect from the context menu

  5. In the Developer Tools panel that opens, look for an <iframe> tag (may be above or below the highlighted element)

  6. Find the src="..." attribute within the iframe tag

  7. Right-click on the URL inside the quotation marks and select Open in new tabโ€‹

Step 2: Train your robot on the direct URL

Now that you have the direct URL of the content, you can:

  1. Copy this URL

  2. Create a new robot in Browse AI

  3. Use this direct URL as your starting point

  4. Train your robot to capture the data you need

This workaround successfully handles over 95% of iFrame situations our users encounter.

What if this doesn't work?

If you can't find a src attribute or if the direct URL doesn't work properly, your case might fall into the 5% where this workaround isn't effective. For these situations:

  • Check if the website offers an API or data feed as an alternative

  • Contact our support team with details about your specific use case, especially if it involves high-volume data extraction

Did this answer your question?