Skip to main content

CDN Detection

free
GET/v1/domain/cdn

Identifies the CDN(s) serving a domain — including layered deployments (Fastly fronting CloudFront, Cloudflare in front of AWS) — by analyzing HTTP headers, DNS records, and the Via header. Classifies each provider as a pure CDN, a hosting platform (Vercel, Netlify), or an edge runtime (Fly.io, Workers).

What It Does

Examines HTTP response headers (CF-Ray, X-Amz-Cf-Id, X-Fastly-Request-Id, X-Vercel-Id, etc.) and DNS CNAME records (e.g. *.cloudfront.net, *.akamaiedge.net) to identify CDN providers. Collects ALL matching providers (not just the first) and derives topology — `single` when one provider is detected, `layered` when ≥2 fire on the same response. Layered chains are ordered by the Via header when present, otherwise by confidence. Detects 19 providers including Cloudflare, CloudFront, Akamai, Fastly, Google Cloud CDN, Azure CDN, Vercel, Netlify, Bunny CDN, Edgio, Alibaba Cloud CDN, and more.

Why It's Useful

CDN identification reveals infrastructure choices, potential DDoS protection levels, and helps understand caching behavior. It's useful for competitive analysis and security assessments.

Use Cases

Solutions Architect

Infrastructure Analysis

Analyze competitor CDN choices to inform your own infrastructure decisions.

Make informed CDN selection based on market leader choices.

Security Analyst

DDoS Assessment

Identify CDN-based DDoS protection during security assessments.

Understand target's DDoS protection capabilities.

Performance Engineer

Performance Debugging

Identify CDN in use to properly interpret cache headers and optimize performance.

Debug caching issues with CDN-specific knowledge.

Parameters

NameTypeRequiredDescription
domainstringRequiredDomain or full URL — accepts `example.com` or `https://example.com/path`.Example: https://example.com

Response Fields

FieldTypeDescription
domainstringThe queried domain (bare hostname).
urlstringFull URL that was fetched, echoing the protocol used in the request.
detectedbooleanWhether at least one CDN/hosting-platform was detected
cdnobjectPrimary CDN: { name, type ("cdn" | "hosting-platform" | "edge-runtime"), confidence, evidence }, or null when none detected
cnamestringCNAME record if present
cnameChainarrayResolved CNAME chain (up to 3 hops) used to catch CDNs behind aliases
topologystring"single" when one provider is detected, "layered" for multi-CDN deployments (Fastly fronting CloudFront, etc.), null when undetermined
topologyChainarrayOrdered chain of CDN names for layered deployments (Via-header-ordered when present)
providersarrayAll detected providers (≥1 when layered) each with name, type, confidence, evidence

Code Examples

cURL
curl "https://api.edgedns.dev/v1/domain/cdn" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d "domain=https://example.com"
JavaScript
const response = await fetch(
  'https://api.edgedns.dev/v1/domain/cdn?domain=https%3A%2F%2Fexample.com',
  {
    headers: {
      'Authorization': 'Bearer YOUR_API_KEY'
    }
  }
);

const data = await response.json();
console.log(data);
Python
import requests

response = requests.get(
    'https://api.edgedns.dev/v1/domain/cdn',
    headers={'Authorization': 'Bearer YOUR_API_KEY'},
    params={
    'domain': 'https://example.com'
    }
)

data = response.json()
print(data)

Read the full CDN Detection guide

Why it matters, real-world use cases, parameters, response fields, and how to call it from Claude, ChatGPT, or Gemini via MCP.

Read the guide →

Related Endpoints

External References

Learn more about the standards and protocols behind this endpoint.

Try This Endpoint

Test the CDN Detection endpoint live in the playground.