Skip to main content

Competitive Analysis API

pro
GET/v1/composite/competitive

Compares SEO, accessibility, privacy, and HTTP-security-header scores across 2-5 domains with ranked results and gap analysis. Identifies the best-performing domain in each of the four categories, calculates the score gap between each domain and the leader, and provides an overall competitive ranking only for complete four-area observations. Weighted 30% SEO / 30% accessibility / 20% privacy / 20% security — matches the website-health composite when equivalent complete scope is available.

What It Does

Accepts a comma-separated list of 2-5 domains, runs SEO scoring, accessibility audits, privacy audits, and HTTP security-headers audits for each domain in parallel, and returns a side-by-side comparison. Each domain retains available category scores. An overall score, grade, rank and overall-leader gap require complete observations in all four categories. Incomplete entries expose partialOverallScore and overallAssessment coverage/scope and cannot lead the aggregate comparison. Results include ranked positions, gap analysis showing point differences from the leader in each category, and identification of the top performer per dimension. Handles partial failures — if one domain's audit fails, others still return with scores.

Why It's Useful

Competitive benchmarking typically requires multiple tools and manual data aggregation. This endpoint automates the entire workflow — run one request and get a complete competitive landscape across SEO, accessibility, and privacy. Essential for SEO strategists identifying optimization gaps, agencies building pitch decks with data-driven comparisons, and teams comparing static accessibility observations across industry peers.

Use Cases

SEO Strategist

SEO Gap Analysis

Compare your domain's SEO, accessibility, and privacy scores against top 3-4 competitors. Identify specific score gaps and which dimensions offer the highest improvement potential.

Quantified competitive gaps with ranked results showing exactly where you lead and lag.

Compliance / Legal Team

Static accessibility comparison

Compare equivalent static accessibility observations across peers to prioritize browser/manual review. These scores do not establish WCAG conformance or legal risk.

Scoped technical findings to guide accessibility evaluation.

Digital Agency

Agency Pitch & Reporting

Generate competitive analysis reports for prospects showing their scores against competitors, highlighting improvement potential across SEO, accessibility, and privacy.

Data-driven pitch decks with quantified improvement potential and ranked competitive positions.

Parameters

NameLocationTypeRequiredDescription
domainsquerystringRequiredComma-separated list of 2-5 domains to compareExample: example.com,competitor1.com,competitor2.com
force_refreshquerystringOptionalBypass the cached composite when true or 1. Does not guarantee every upstream source is fresh.Example: trueOptions: true, 1

Response Fields

Result fields below are inside the JSON data object. Any row named meta describes the sibling response metadata object. See response and error handling for status codes and error responses. Optional observations may be absent or null; inspect warnings and partial-failure fields before treating a missing result as a negative finding.

FieldTypeDescription
domains[].partialOverallScorenumber|nullWeighted average of observed categories for an incomplete entry; diagnostic only and never an overall leader/ranking score.
domains[].overallAssessmentobjectComplete/provisional/unavailable coverage, observed/applicable weights, unavailable required areas and all_four_required_areas comparison scope.
domainsarrayRanked array of domain comparison objects: domain name, SEO score/grade, accessibility score/grade, privacy score/grade, **security score/grade (HSTS / CSP / X-Frame-Options / Referrer-Policy / Permissions-Policy)**, overall composite score/grade (weighted 30/30/20/20), overallGradeDescription and rank only for complete four-area entries; incomplete entries use null definitive score/grade/rank and retain partialOverallScore plus overallAssessment coverage/scope, and gap from leader in each category (null gap indicates the score could not be computed, not zero difference)
comparisonobjectBest performer identification: bestSeo, bestAccessibility, bestPrivacy, bestSecurity, bestOverall — each with domain name and score
metaobjectRequest metadata: domains_analyzed, response_time_ms, partial_failure flag
partialFailurebooleanWhether any component failed; inspect per-domain errors and warnings.

Code Examples

Replace YOUR_API_KEY with your API key. This endpoint requires the pro plan or higher; see plans and usage limits.

cURL
curl --request GET 'https://api.edgedns.dev/v1/composite/competitive?domains=example.com%2Ccompetitor1.com%2Ccompetitor2.com' \
  --header "Authorization: Bearer YOUR_API_KEY"
JavaScript
const response = await fetch(
  "https://api.edgedns.dev/v1/composite/competitive?domains=example.com%2Ccompetitor1.com%2Ccompetitor2.com",
  {
    "method": "GET",
    "headers": {
      "Authorization": "Bearer YOUR_API_KEY"
    }
  }
);

if (!response.ok) {
  throw new Error(`EdgeDNS returned HTTP ${response.status}`);
}
const data = await response.json();
console.log(data);
Python
import requests

response = requests.request(
    'GET',
    "https://api.edgedns.dev/v1/composite/competitive?domains=example.com%2Ccompetitor1.com%2Ccompetitor2.com",
    headers={'Authorization': 'Bearer YOUR_API_KEY'},
    timeout=60,
)
response.raise_for_status()
data = response.json()
print(data)

Read the full Competitive Analysis guide

Learn the concepts, choose a practical workflow, and interpret the observations from Competitive Analysis before acting on them. Run supported checks via MCP or through REST.

Read the guide →

Related Endpoints

External References

Learn more about the standards and protocols behind this endpoint.

Try This Endpoint

Test the Competitive Analysis endpoint live in the playground.

Competitive Analysis API Reference | EdgeDNS