Redirect Chain Checker avatar

Redirect Chain Checker

Pricing

from $2.00 / 1,000 url checkeds

Go to Apify Store
Redirect Chain Checker

Redirect Chain Checker

Analyze HTTP redirect chains for any URL. Returns full redirect path, final URL, status codes, and loop detection. Perfect for SEO audits and affiliate link checks.

Pricing

from $2.00 / 1,000 url checkeds

Rating

0.0

(0)

Developer

Harsh

Harsh

Maintained by Community

Actor stats

0

Bookmarked

3

Total users

2

Monthly active users

2 days ago

Last modified

Share

Analyze HTTP redirect chains for any URL — no browser required.

Redirect Chain Checker is an Apify Actor built for SEO professionals, developers, and marketers who need to audit how URLs resolve across the web. Enter one or more URLs and get a complete picture of every hop: status codes, Location headers, final destination, redirect count, loop detection, and response times.

Ideal for:

  • SEO audits — verify 301/302 chains, spot redirect loops, and confirm canonical destinations
  • Affiliate link checks — trace tracking URLs to their landing pages
  • Site migrations — validate redirect rules after domain or path changes
  • API & integration testing — confirm endpoints resolve as expected

Features

  • Follows HTTP redirects manually (301, 302, 303, 307, 308) using native fetch
  • Returns the full redirect chain with status codes and Location headers
  • Detects redirect loops automatically
  • Configurable max redirects, per-request timeout, and custom User-Agent
  • Processes multiple URLs in a single run
  • Graceful error handling — failed URLs are recorded without stopping the run

Input

FieldTypeRequiredDefaultDescription
urlsstring[]YesURLs to check for redirect chains
maxRedirectsintegerNo10Max redirects to follow per URL (1–50)
timeoutMsintegerNo10000Per-request timeout in milliseconds
userAgentstringNoApifyRedirectChecker/1.0User-Agent header for requests

Example input

{
"urls": [
"https://httpbin.org/redirect/3",
"https://google.com"
],
"maxRedirects": 10,
"timeoutMs": 10000
}

Output

Each checked URL produces one dataset item:

FieldTypeDescription
inputUrlstringOriginal URL submitted
finalUrlstringFinal URL after all redirects
statusCodeintegerHTTP status of the final response
redirectChainarrayOrdered hops: { url, status, location }
totalRedirectsintegerNumber of redirect responses
isLoopbooleantrue if a redirect loop was detected
responseTimeMsintegerTotal time to resolve the chain (ms)
errorstringPresent only when the check failed

Example output

{
"inputUrl": "https://httpbin.org/redirect/3",
"finalUrl": "https://httpbin.org/get",
"statusCode": 200,
"redirectChain": [
{ "url": "https://httpbin.org/redirect/3", "status": 302, "location": "/redirect/2" },
{ "url": "https://httpbin.org/redirect/2", "status": 302, "location": "/redirect/1" },
{ "url": "https://httpbin.org/redirect/1", "status": 302, "location": "/get" },
{ "url": "https://httpbin.org/get", "status": 200, "location": null }
],
"totalRedirects": 3,
"isLoop": false,
"responseTimeMs": 1240
}

How it works

  1. The Actor reads urls from input and processes each one sequentially.
  2. For each URL, it sends HTTP GET requests with redirect: 'manual' so redirects are not followed automatically.
  3. On 3xx responses, it reads the Location header and follows the chain until a non-redirect response, a loop, an error, or maxRedirects is reached.
  4. Results are saved to the default dataset via Actor.pushData().

Run locally

$apify run

Set test input in storage/key_value_stores/default/INPUT.json:

{
"urls": ["https://httpbin.org/redirect/3", "https://google.com"]
}

Deploy to Apify

apify login
apify push

Resources