Robust Image Retrieval with BrightData Web Unblocker Failover - n8n Workflow

Use this powerful n8n workflow to reliably fetch images from difficult sources. It features a standard HTTP Request combined with a BrightData Web Unlocker failover for blocked resources. Get started with n8n templates today.

Workflow Preview

Ready to automate?

Download this n8n workflow template and start using it instantly.

Who is this best for?

Data analysts and scrapers who need guaranteed access to image assets.
Users facing frequent geo-blocking or anti-bot measures when fetching public images.
n8n automation specialists looking for advanced failover logic in their n8n templates.
Developers requiring resilient file fetching logic without external code.

Overview

When building data pipelines using n8n, reliably fetching assets like images can be challenging due to anti-bot measures or rate limiting. This specialized n8n workflow solves this by utilizing a two-stage approach.

The initial attempt uses a standard n8n node, the HTTP Request node, for maximum speed and efficiency. If this attempt fails—perhaps the site is protected or requires advanced rendering—the flow automatically switches to the failover path. The failover leverages BrightData's Web Unlocker, a powerful commercial proxy service, to access the image. This clever application of the n8n node error handling capability ensures that your n8n workflow achieves the highest possible success rate for fetching critical image files. This is a crucial design pattern for complex web scraping and extraction tasks within the n8n environment.

How it Works

This resilient image-fetching n8n workflow operates using conditional flow control based on the success of the primary retrieval step.


  1. Start: The process begins with the Manual n8n trigger, initiating the execution when clicked.

  2. Define Target: An n8n node (Set) defines the target variable image containing the URL of the image to be retrieved (e.g., https://example.com/image.jpg).

  3. Primary Attempt (Classic Image Getter): An HTTP Request n8n node attempts to fetch the image directly. Crucially, this n8n node is configured to 'Continue on Error' (onError: continueErrorOutput).

  4. Success Path: If the standard fetch succeeds, the data passes through the primary connection path (which is not explicitly defined in the provided JSON, implying the workflow ends or continues there).

  5. Failover Path (Unlock Image): If the 'Classic Image Getter' fails (i.e., returns a 4xx or 5xx status code), the execution is routed to the failover path. The 'Unlock Image' n8n node takes over. This n8n node sends a POST request to the BrightData API, utilizing the 'web_unlocker' zone to bypass blocks and retrieve the image data. This failover mechanism ensures the n8n workflow remains robust.

Installation Guide

To deploy this powerful n8n workflow, follow these steps:


  1. Import: Copy the provided n8n workflow JSON code and paste it into your n8n instance using the 'New' -> 'Import from JSON' option.

  2. Credentials: This n8n workflow requires credentials for BrightData Web Unlocker.

Open the 'Unlock Image' n8n node.
In the Header Parameters, locate the Authorization header.
* Replace {{BRIGHTDATA_TOKEN}} with an expression pointing to your secure BrightData API token credential, or set it as a global environment variable in your n8n setup.

  1. Configuration: Update the 'image' Set n8n node with the actual image URL you wish to retrieve.

  2. Execution: Click the 'When clicking ‘Execute workflow’' n8n trigger to test the sequence. The result will either be the image content from the standard fetch or the unlocked image content from BrightData.

Node Details

When clicking ‘Execute workflow’ (Manual Trigger): The starting n8n trigger for testing and manual initiation of the n8n workflow.
image (Set Node): Used to initialize the key variable image (the target URL). This centralizes the input for the entire n8n workflow.
Classic Image Getter (HTTP Request Node): The primary attempt to fetch the image.
Function: Executes a simple GET request.
Key Configuration: onError: continueErrorOutput. This is vital, as it allows the n8n node to fail and pass execution to the subsequent error path, triggering the BrightData failover.
Unlock Image (HTTP Request Node): The dedicated failover n8n node.
Function: Routes the request through the BrightData Web Unlocker API.
Key Configuration: Method is POST. Sends body parameters specifying zone: webunlocker and the target url. Requires an Authorization header using the BRIGHTDATATOKEN secret.

Related n8n Workflows

Free

Nodes: 4 Nodes
Updated: December 26 2025
View all
Created by

e-com AI automation: 90% time saved on repetitive tasks: product sheets, after-sales chatbots, etc. 🚀 save time, win customers

Featured*