Website Speed Test API | Page Load Speed API - V2.0 - VebAPI

Speed Check

Check your website speed and get suggestions to improve it.

Speed Check

GET Version: 2.0
GET /seo/loadingspeeddata/v2

Parameters

website
Required query
string

enter website url

X-API-KEY
Required header
string

Your Vebapi API Key

Example Request


curl -X GET "https://vebapi.com/api/seo/loadingspeeddata/v2?website=vebapi.com" \
  -H "X-API-KEY: YOUR_API_KEY"\
  -H "Content-Type: application/json"

Response

{
    "api": {
        "name": "website speed check",
        "provider": "vebapi.com",
        "engine": "v3-domain-master",
        "server": "EU-4",
        "version": "3"
    },
    "summary": {
        "url": "https://vebapi.com/",
        "performance_grade": {
            "score": 97,
            "grade": "A"
        },
        "page_size_bytes": 532033,
        "page_size_kb": 519.6,
        "load_time_ms": 534,
        "ttfb_ms": 532,
        "requests": 29,
        "unique_domains": 6,
        "main": {
            "http_code": 200,
            "content_type": "text/html; charset=UTF-8",
            "header_size": 1581,
            "html_size_bytes": 98218,
            "redirect_count": 0,
            "timings": {
                "namelookup_time": 0.008848,
                "connect_time": 0.013405,
                "appconnect_time": null,
                "pretransfer_time": 0.037235,
                "starttransfer_time": 0.531967,
                "total_time": 0.534037,
                "redirect_time": 0
            }
        }
    },
    "improve_page_performance": [
        {
            "grade": "C",
            "suggestion": "Add Expires headers / Cache-Control",
            "detail": "3 asset(s) missing strong caching"
        }
    ],
    "response_codes": [
        {
            "response_code": 200,
            "responses": 29
        }
    ],
    "content_size_by_content_type": [
        {
            "content_type": "Script",
            "percent": 52.31,
            "size_kb": 271.8
        },
        {
            "content_type": "Image",
            "percent": 29.18,
            "size_kb": 151.6
        },
        {
            "content_type": "HTML",
            "percent": 18.46,
            "size_kb": 95.9
        },
        {
            "content_type": "CSS",
            "percent": 0.05,
            "size_kb": 0.2
        },
        {
            "content_type": "Other",
            "percent": 0,
            "size_kb": 0
        }
    ],
    "requests_by_content_type": [
        {
            "content_type": "Image",
            "percent": 79.31,
            "requests": 23
        },
        {
            "content_type": "Script",
            "percent": 10.34,
            "requests": 3
        },
        {
            "content_type": "CSS",
            "percent": 3.45,
            "requests": 1
        },
        {
            "content_type": "Other",
            "percent": 3.45,
            "requests": 1
        },
        {
            "content_type": "HTML",
            "percent": 3.45,
            "requests": 1
        }
    ],
    "content_size_by_domain": [
        {
            "domain": "vebapi.com",
            "percent": 47.64,
            "size_kb": 247.5
        },
        {
            "domain": "www.googletagmanager.com",
            "percent": 28.06,
            "size_kb": 145.8
        },
        {
            "domain": "cdn.tailwindcss.com",
            "percent": 23.75,
            "size_kb": 123.4
        },
        {
            "domain": "analytics.ahrefs.com",
            "percent": 0.51,
            "size_kb": 2.6
        },
        {
            "domain": "fonts.googleapis.com",
            "percent": 0.05,
            "size_kb": 0.2
        },
        {
            "domain": "www.facebook.com",
            "percent": 0,
            "size_kb": 0
        }
    ],
    "requests_by_domain": [
        {
            "domain": "vebapi.com",
            "percent": 82.76,
            "requests": 24
        },
        {
            "domain": "fonts.googleapis.com",
            "percent": 3.45,
            "requests": 1
        },
        {
            "domain": "cdn.tailwindcss.com",
            "percent": 3.45,
            "requests": 1
        },
        {
            "domain": "www.googletagmanager.com",
            "percent": 3.45,
            "requests": 1
        },
        {
            "domain": "analytics.ahrefs.com",
            "percent": 3.45,
            "requests": 1
        },
        {
            "domain": "www.facebook.com",
            "percent": 3.45,
            "requests": 1
        }
    ],
    "file_requests": [
        {
            "url": "https://www.googletagmanager.com/gtag/js?id=G-ZRZKZGFQYL",
            "domain": "www.googletagmanager.com",
            "status": 200,
            "type": "Script",
            "size_bytes": 149270,
            "timings": {
                "namelookup_time": 0.003021,
                "connect_time": 0.014663,
                "appconnect_time": null,
                "pretransfer_time": 0.243868,
                "starttransfer_time": 0.3015,
                "total_time": 0.321054,
                "redirect_time": 0
            },
            "content_type": "application/javascript; charset=UTF-8",
            "error": null
        },
        {
            "url": "https://cdn.tailwindcss.com/3.4.17",
            "domain": "cdn.tailwindcss.com",
            "status": 200,
            "type": "Script",
            "size_bytes": 126350,
            "timings": {
                "namelookup_time": 0.0029,
                "connect_time": 0.006457,
                "appconnect_time": null,
                "pretransfer_time": 0.241844,
                "starttransfer_time": 0.309898,
                "total_time": 0.321787,
                "redirect_time": 0.301471
            },
            "content_type": "text/javascript",
            "error": null
        },
        {
            "url": "https://vebapi.com/",
            "domain": "vebapi.com",
            "status": 200,
            "type": "HTML",
            "size_bytes": 98218,
            "timings": {
                "namelookup_time": 0.008848,
                "connect_time": 0.013405,
                "appconnect_time": null,
                "pretransfer_time": 0.037235,
                "starttransfer_time": 0.531967,
                "total_time": 0.534037,
                "redirect_time": 0
            },
            "content_type": "text/html; charset=UTF-8",
            "error": null
        },
        {
            "url": "https://www.facebook.com/tr?id=759383993705951&ev=PageView&noscript=1",
            "domain": "www.facebook.com",
            "status": 200,
            "type": "Other",
            "size_bytes": 0,
            "timings": {
                "namelookup_time": 0.00386,
                "connect_time": 0.219957,
                "appconnect_time": null,
                "pretransfer_time": 0.29615,
                "starttransfer_time": 0.310841,
                "total_time": 0.310867,
                "redirect_time": 0
            },
            "content_type": "text/plain",
            "error": null
        }
    ]
}

Website Speed Check API

The Website Speed Check API analyzes a single URL and returns page performance metrics, request breakdowns, response codes, and per-file timing details.

API Metadata

Field Example Description
name website speed check API name
provider vebapi.com Service provider
engine v3-domain-master Backend engine identifier
server EU-4 Serving region/node
version 3 API version

 

Response

Successful response is JSON with these top-level keys:

Key Type Description
api object Metadata about the API engine and server.
summary object High-level performance metrics for the URL.
improve_page_performance array Actionable recommendations with grades.
response_codes array Counts of HTTP status codes across fetched resources.
content_size_by_content_type array Bandwidth contribution by resource type.
requests_by_content_type array Request count contribution by resource type.
content_size_by_domain array Bandwidth contribution by domain.
requests_by_domain array Request count contribution by domain.
file_requests array Per-file fetch details (URL, size, timings, content-type, error).

Field Reference

summary

Field Type Description
url string Final tested URL (after normalization).
performance_grade object Overall score + letter grade.
performance_grade.score integer 0–100 score.
performance_grade.grade string Letter grade, e.g. A/B/C.
page_size_bytes integer Total bytes downloaded across fetched resources.
page_size_kb number Total KB downloaded across fetched resources.
load_time_ms integer Total load time for the main document in milliseconds.
ttfb_ms integer Time-to-first-byte for the main document in milliseconds.
requests integer Total number of requests fetched.
unique_domains integer Number of distinct domains used by resources.
main object Main document request details.

summary.main

Field Type Description
http_code integer HTTP status of the main document.
content_type string Content-Type header of the main document.
header_size integer Response header size (bytes) for main document.
html_size_bytes integer Main HTML size (bytes).
redirect_count integer Redirect hops for the main document.
timings object cURL-style timing breakdown for main document (seconds).

timings

Timings are expressed in seconds (floating point). Convert to ms by multiplying by 1000.

Field Type Description
namelookup_time number DNS resolution time.
connect_time number TCP connect time.
appconnect_time number or null TLS handshake time (if HTTPS) when available.
pretransfer_time number Time until transfer begins.
starttransfer_time number Time to first byte (TTFB) in seconds.
total_time number Total request time.
redirect_time number Time spent following redirects.

improve_page_performance

Field Type Description
grade string Letter grade for this rule (A–F).
suggestion string Recommendation title.
detail string Short explanation and count of affected assets.

response_codes

Field Type Description
response_code integer HTTP status code.
responses integer Number of resources returning this code.

content_size_by_content_type

Field Type Description
content_type string Resource category (Script, Image, HTML, CSS, Other).
percent number Percent of total downloaded size.
size_kb number Total size for this category in KB.

requests_by_content_type

Field Type Description
content_type string Resource category (Image, Script, CSS, Other, HTML).
percent number Percent of total requests.
requests integer Number of requests in this category.

content_size_by_domain

Field Type Description
domain string Hostname for the resource.
percent number Percent of total downloaded size.
size_kb number Total size for this domain in KB.

requests_by_domain

Field Type Description
domain string Hostname for the resource.
percent number Percent of total requests.
requests integer Total requests made to this domain.

file_requests

Field Type Description
url string Full resource URL fetched.
domain string Hostname extracted from the URL.
status integer HTTP status code for the resource.
type string Resource category (Script, Image, HTML, CSS, Other).
size_bytes integer Downloaded size in bytes (may be 0 for some beacons).
timings object Timing breakdown for this file (seconds).
content_type string Response Content-Type header.
error string or null Error message if the request failed, otherwise null.

 

Error Responses

HTTP Code When Example Body
400 Missing or invalid url parameter {"error":"Missing url parameter"}
401 Missing/invalid API key {"error":"Unauthorized"}
429 Rate limit exceeded {"error":"Rate limit exceeded"}
500 Unexpected server error {"error":"Internal server error"}

 

Changelog

Version Changes
3 Initial public version of Website Speed Check response schema.