Skip to main content

Performance Score API

pro
GET/v1/score/performance

Combines compression, caching, response timing, resource hints, CDN detection and measured HTTP protocol support into a performance score. Native protocol measurements are distinct from DNS and Alt-Svc advertisements.

What It Does

Uses actual HTTP/2 and HTTP/3 negotiation for the HTTP-version component. Other performance checks continue to measure HTTP responses and available field data through their existing services. Returns component findings and validation outcomes, retaining unknown protocol results when a probe cannot complete.

Why It's Useful

Compare like-for-like HTTP observations and prioritize investigations using evidence coverage and sample metadata. This product-policy composite is separate from browser performance and CrUX field assessment; validate user-experience improvements with browser or real-user measurements.

Use Cases

Product Manager / SEO Manager

Competitive Performance Benchmarking

Score your domain and competitor domains to establish performance benchmarks. Track scores monthly to measure the impact of infrastructure investments. Compare HTTP version adoption, compression, and CDN usage across your competitive landscape.

Data-driven performance targets based on competitive analysis rather than arbitrary thresholds.

Performance Engineer / SRE

Infrastructure Optimization Prioritization

Use the component breakdown to identify the highest-impact optimization opportunities. A domain scoring 5/20 on HTTP version (HTTP/1.1) with 0/20 on compression has clear, actionable priorities. Track score improvements after each infrastructure change.

Focus optimization effort on the changes that will move the score most — avoid wasting time on marginal improvements.

Web Developer / DevOps Engineer

Pre-Launch Performance Validation

Run performance score checks as part of CI/CD pipelines before deploying to production. Set minimum score thresholds (e.g., grade B or above) as deployment gates. Catch misconfigurations like missing compression headers or cache policies before users are affected.

Prevent performance regressions from reaching production — catch missing Cache-Control headers, disabled compression, and protocol downgrades automatically.

Infrastructure Architect

Vendor & CDN Performance Assessment

Compare performance scores before and after CDN migrations, hosting changes, or origin server upgrades. Evaluate whether a CDN provider actually improves TTFB, compression, and cache hit rates for your specific traffic patterns.

Quantified infrastructure investment ROI — measure the actual performance impact of hosting and CDN decisions.

Parameters

NameLocationTypeRequiredDescription
domainquerystringRequiredThe domain to calculate performance score for. TTFB is measured via HTTPS request.Example: google.com
samplesquerynumberOptionalNumber of eligible HTTP response samples for median synthetic headers timing (1-5, default: 3).Example: 3

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
domainstringThe scored domain
assessmentobjectComplete/provisional/unavailable assessment, percentage coverage and observed/applicable weights; unavailable evidence is not N/A.
timingobjectRequested/successful/failed samples, median and individual synthetic HTTP outcomes; failed samples receive no passing credit.
observationsobjectUnderlying compression, cache and hint observations with source-specific scope; not browser page-load measurements.
scorenumberComposite performance score 0-100 (weighted sum of 6 components)
gradestringGrade for complete comparable evidence; null when provisional, with provisionalGrade retained for diagnostic use
gradeDescriptionstringHuman-readable description of the grade level
breakdownobjectComponent scores, observed/unavailable/not_applicable status, reason and confidence
breakdown.compressionobjectCompression analysis from the dedicated compression endpoint — Brotli, Gzip, Zstd, Deflate, or none (max 20 pts)
breakdown.httpVersionobjectNegotiated HTTP support when native measurements complete; advertisements alone leave this component unavailable (max 20 pts)
breakdown.cacheobjectStorage, freshness, revalidation and privacy policy evidence; sensitive no-store/private contexts are not penalized for shared-cache optimization (max 20 pts)
breakdown.responseTimeobjectMedian response timing across requested samples; inspect sample completion and failure metadata (max 20 pts)
breakdown.resourceHintsobjectpreconnect, preload, dns-prefetch from HTML + Link headers. Marked notApplicable for non-HTML responses (max 10 pts)
breakdown.cdnobjectCDN provider detection — 22+ providers identified (max 10 pts)
recommendationsarrayRecommendations sorted by descending estimated point impact, with "+N pts" suffix
recommendationsWithImpactarrayStructured recommendations: [{ message, estimatedImpact: { metric: "score", value } }]
cwvobjectChrome User Experience Report field data — { hasData, origin, byFormFactor: { all, phone, desktop } }. Each form-factor record carries p75 readings for LCP, INP, CLS, TTFB, FCP. availability distinguishes available, insufficient_data, not_configured and upstream_error; device records include matched origin, collection period and core-metric completeness
partialFailurebooleanTrue when one or more sub-component evaluations failed; check failedComponents and confidence per breakdown entry
failedComponentsarrayNames of sub-components that failed to evaluate (e.g. "compression", "cache")
componentCountnumberNumber of scoring components evaluated

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/score/performance?domain=google.com' \
  --header "Authorization: Bearer YOUR_API_KEY"
JavaScript
const response = await fetch(
  "https://api.edgedns.dev/v1/score/performance?domain=google.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/score/performance?domain=google.com",
    headers={'Authorization': 'Bearer YOUR_API_KEY'},
    timeout=60,
)
response.raise_for_status()
data = response.json()
print(data)

Read the full Performance Score guide

Learn the concepts, choose a practical workflow, and interpret the observations from Performance Score 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 Performance Score endpoint live in the playground.

Performance Score API Reference | EdgeDNS