VOOZH about

URL: https://apify.com/taroyamada/url-shortener-resolver

โ‡ฑ URL Redirect Scraper: Trace Hops & Unshorten Links ยท Apify


Pricing

Pay per event

Go to Apify Store

Short URL Resolver & Scraper

Trace redirect chains and expand short URLs without executing browser scripts. Extract complete hop histories, identify infinite loops, and verify HTTP status.

Pricing

Pay per event

Rating

0.0

(0)

Developer

๐Ÿ‘ naoki anzai

naoki anzai

Maintained by Community

Actor stats

0

Bookmarked

8

Total users

2

Monthly active users

22 days ago

Last modified

Share

๐Ÿ”— URL Unshortener

Trace redirect chains and safely unshorten obfuscated links without risking execution in a standard web browser. Scraping the web often yields datasets filled with tinyurl, bit.ly, or custom short links that mask the true destination. Processing these blindly can lead your crawlers into infinite redirect loops or expose your systems to malicious payloads. This resolver acts as a hardened proxy, systematically expanding shortened URLs to extract the final destination link while safely discarding any executable scripts. Developers and data engineers use this tool to sanitize massive URL lists, schedule automated link-checking workflows, and validate data integrity before loading it into downstream databases. By running this extraction process, you gain deep visibility into the exact path a URL takes. The results explicitly detail every intermediate hop, logging the exact HTTP status codes (like 301, 302, or 404) encountered along the way. You can seamlessly identify broken links, detect insecure HTTP downgrades, and flag toxic domains. Ensure your scraped contact details and website lists contain only clean, verified, and direct endpoints.

๐Ÿ“„ Live sample output: see docs/sample-output.json for a representative dataset captured from a real run of this actor. Use it to validate the schema before subscribing.

Store Quickstart

Start with the Quickstart template (3 demo shortened URLs). For bulk processing, use Bulk Resolve (1,000 URLs, concurrency 20).

Key Features

  • ๐Ÿ”“ Expand all shorteners โ€” Works with bit.ly, t.co, goo.gl, tinyurl, ow.ly, buff.ly, and more
  • ๐Ÿ”— Full redirect chain โ€” Every hop logged with URL + status code
  • ๐Ÿ”„ Loop detection โ€” Identifies infinite redirect loops and cyclic redirects
  • ๐Ÿ”’ HTTPS downgrade detection โ€” Flags URLs where https redirects to http
  • โšก Bulk processing โ€” Up to 1,000 URLs per run with 1-20 concurrency
  • ๐Ÿ“Š Hop count stats โ€” Total hops per URL for ad network / tracker analysis

Use Cases

WhoWhy
Ad fraud analystsDetect cloaking by tracing redirect chains in ad URLs
Security teamsResolve phishing links without clicking to identify payloads
Social media analystsExpand t.co links from X/Twitter datasets for attribution
SEO auditorsVerify outbound shortened links resolve to intended destinations
Journalism/OSINTInvestigate URL patterns in misinformation campaigns

Input

FieldTypeDefaultDescription
urlsstring[](required)Shortened URLs to resolve (max 1000)
maxRedirectsinteger10Max redirect hops (1-20)
concurrencyinteger10Parallel requests (1-20)

Input Example

{
"urls":["https://bit.ly/3abcdef","https://t.co/xyz","https://goo.gl/abc123"],
"maxRedirects":10,
"concurrency":10
}

Input Examples

Example: Resolve single short URL

{
"urls":[
"https://bit.ly/abc"
]
}

Example: Bulk batch with safety advisory

{
"urls":[
"https://bit.ly/x1",
"https://t.co/abc",
"https://tinyurl.com/y3"
],
"includeSafetyAdvisory":true
}

Example: Phishing detection workflow

{
"urls":[
"https://bit.ly/suspicious"
],
"maxRedirectChain":10,
"recordIntermediateRedirects":true,
"abortOnLoop":true
}

Output

FieldTypeDescription
originalUrlstringThe short URL provided as input
finalUrlstringThe final destination URL after all redirects
redirectChainstring[]Full chain of intermediate URLs
totalHopsintegerNumber of redirects followed
hasLoopbooleanTrue if a redirect loop was detected
isHttpsDowngradebooleanTrue if any HTTPSโ†’HTTP downgrade occurred
statusCodeintegerFinal HTTP status code
errorstringnull

Output Example

{
"originalUrl":"https://bit.ly/3abcdef",
"chain":[
{"url":"https://bit.ly/3abcdef","statusCode":301},
{"url":"https://example.com/landing","statusCode":200}
],
"finalUrl":"https://example.com/landing",
"totalHops":2,
"hasLoop":false,
"isHttpsDowngrade":false
}

API Usage

Run this actor programmatically using the Apify API. Replace YOUR_API_TOKEN with your token from Apify Console โ†’ Settings โ†’ Integrations.

cURL

curl-X POST "https://api.apify.com/v2/acts/taroyamada~url-shortener-resolver/run-sync-get-dataset-items?token=YOUR_API_TOKEN"\
-H"Content-Type: application/json"\
-d'{ "urls": ["https://bit.ly/3abcdef", "https://t.co/xyz", "https://goo.gl/abc123"], "maxRedirects": 10, "concurrency": 10 }'

Python

from apify_client import ApifyClient
client = ApifyClient("YOUR_API_TOKEN")
run = client.actor("taroyamada/url-shortener-resolver").call(run_input={
"urls":["https://bit.ly/3abcdef","https://t.co/xyz","https://goo.gl/abc123"],
"maxRedirects":10,
"concurrency":10
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
print(item)

JavaScript / Node.js

import{ ApifyClient }from'apify-client';
const client =newApifyClient({token:'YOUR_API_TOKEN'});
const run =await client.actor('taroyamada/url-shortener-resolver').call({
"urls":["https://bit.ly/3abcdef","https://t.co/xyz","https://goo.gl/abc123"],
"maxRedirects":10,
"concurrency":10
});
const{ items }=await client.dataset(run.defaultDatasetId).listItems();
console.log(items);

Tips & Limitations

  • Detect malicious URL chains by checking hasLoop and isHttpsDowngrade flags.
  • Default maxRedirects: 10 is safe for legitimate shorteners. Increase only if needed.
  • Use this before clicking any unknown short link in security-sensitive workflows.
  • Combine with Meta Tag Analyzer to inspect the destination page metadata.

See also (Link analysis cluster)

FAQ

What if the short URL is dead?

The chain shows the final status code (e.g., 404). hasLoop will be false; finalUrl will be the last URL reached.

Can it handle JavaScript redirects?

No โ€” this is HTTP-level only. JS-based redirects (meta refresh, window.location) require a browser.

Is bit.ly rate-limited?

bit.ly may rate-limit aggressive requests. Use concurrency โ‰ค 10 for safety on shortener-heavy batches.

Will this follow tracking parameters?

Yes. The full URL including UTM tags is preserved at each hop.

Which shorteners are supported?

Any HTTP-based redirect โ€” bit.ly, t.co, tinyurl, goo.gl, lnkd.in, custom shorteners. No special integration needed.

Will it click through tracking pixels?

It follows server-side HTTP redirects only, not JavaScript or meta-refresh redirects.

Related Actors

URL/Link Tools cluster โ€” explore related Apify tools:

Cost

Pay Per Event:

  • actor-start: $0.01 (flat fee per run)
  • dataset-item: $0.002 per output item

Example: 1,000 items = $0.01 + (1,000 ร— $0.002) = $2.01

No subscription required โ€” you only pay for what you use.

๐Ÿ’พ Save it for later: click the bookmark icon at the top of the Apify Store page if you'd like to come back to it. Bookmarks help other engineers find this actor via Apify's discovery surfaces.

โญ Was Short URL Resolver & Scraper useful for your shortener / phishing-link resolution?

If this actor saved you time, please leave a 5โ˜… rating on Apify Store โ€” it takes 10 seconds, helps other engineers and analysts discover it, and keeps updates free.

Have a feature request, bug, or sample workflow you'd like to share? Open an issue โ€” we read every one and use them to prioritise the next release.

You might also like

HTTP Status Code Checker - Bulk URLs & Redirect Chains

dltik/http-status-checker

Bulk-check HTTP status codes and full redirect chains for any list of URLs. For each URL: final status, every redirect hop (status + Location), response time, content-type and server. Pure HTTP, reads headers only โ€” fast and cheap. Great for SEO migrations, link audits and uptime spot-checks.

URL Shortener Resolver API

andok/url-shortener-resolver

Bulk unshorten URLs and extract complete HTTP redirect chains. Resolve bit.ly, t.co, and others to find the final destination URL and HTTP status code.

Bulk URL Status Checker โ€“ Broken Link & Redirect Audit

logiover/bulk-url-status-checker

Bulk HTTP status code checker and broken link checker. Trace redirect chains, find 404s, export to CSV/JSON. No browser, no login.

URL Redirect Validator

botflowtech/url-redirect-validator

Track complete HTTP redirect chains, detect cross-domain redirects, and validate URLs. Perfect for affiliate link monitoring and ad hijacking detection.

Http Status Scanner

zerobreak/http-status-scanner

HTTP status scanner that checks URL status codes and redirect chains in bulk. Built for SEO teams and developers who need to catch broken links and verify redirects at scale.

Redirect Path Analyzer

zerobreak/redirect-path-analyzer

Redirect path analyzer that follows every hop in a URL chain and reports status codes, redirect types, and the final destination, so SEO teams can fix broken chains before they affect rankings.