Skip to content

Get a DNS health check for GitHub Pages

GET
/repos/{owner}/{repo}/pages/health

Gets a health check of the DNS settings for the CNAME record configured for a repository’s GitHub Pages.

The first request to this endpoint returns a 202 Accepted status and starts an asynchronous background task to get the results for the domain. After the background task completes, subsequent requests to this endpoint return a 200 OK status with the health check results in the response.

The authenticated user must be a repository administrator, maintainer, or have the ‘manage GitHub Pages settings’ permission to use this endpoint.

OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.

API method documentation

owner
required
string

The account owner of the repository. The name is not case sensitive.

repo
required
string

The name of the repository without the .git extension. The name is not case sensitive.

Response

Media type application/json
Pages Health Check Status

Pages Health Check Status

object
domain
object
host
string
uri
string
nameservers
string
dns_resolves
boolean
is_proxied
boolean
nullable
is_cloudflare_ip
boolean
nullable
is_fastly_ip
boolean
nullable
is_old_ip_address
boolean
nullable
is_a_record
boolean
nullable
has_cname_record
boolean
nullable
has_mx_records_present
boolean
nullable
is_valid_domain
boolean
is_apex_domain
boolean
should_be_a_record
boolean
nullable
is_cname_to_github_user_domain
boolean
nullable
is_cname_to_pages_dot_github_dot_com
boolean
nullable
is_cname_to_fastly
boolean
nullable
is_pointed_to_github_pages_ip
boolean
nullable
is_non_github_pages_ip_present
boolean
nullable
is_pages_domain
boolean
is_served_by_pages
boolean
nullable
is_valid
boolean
reason
string
nullable
responds_to_https
boolean
enforces_https
boolean
https_error
string
nullable
is_https_eligible
boolean
nullable
caa_error
string
nullable
alt_domain
object
host
string
uri
string
nameservers
string
dns_resolves
boolean
is_proxied
boolean
nullable
is_cloudflare_ip
boolean
nullable
is_fastly_ip
boolean
nullable
is_old_ip_address
boolean
nullable
is_a_record
boolean
nullable
has_cname_record
boolean
nullable
has_mx_records_present
boolean
nullable
is_valid_domain
boolean
is_apex_domain
boolean
should_be_a_record
boolean
nullable
is_cname_to_github_user_domain
boolean
nullable
is_cname_to_pages_dot_github_dot_com
boolean
nullable
is_cname_to_fastly
boolean
nullable
is_pointed_to_github_pages_ip
boolean
nullable
is_non_github_pages_ip_present
boolean
nullable
is_pages_domain
boolean
is_served_by_pages
boolean
nullable
is_valid
boolean
reason
string
nullable
responds_to_https
boolean
enforces_https
boolean
https_error
string
nullable
is_https_eligible
boolean
nullable
caa_error
string
nullable
Examples
Example default
{
"domain": {
"host": "example.com",
"uri": "http://example.com/",
"nameservers": "default",
"dns_resolves": true,
"is_proxied": false,
"is_cloudflare_ip": false,
"is_fastly_ip": false,
"is_old_ip_address": false,
"is_a_record": true,
"has_cname_record": false,
"has_mx_records_present": false,
"is_valid_domain": true,
"is_apex_domain": true,
"should_be_a_record": true,
"is_cname_to_github_user_domain": false,
"is_cname_to_pages_dot_github_dot_com": false,
"is_cname_to_fastly": false,
"is_pointed_to_github_pages_ip": true,
"is_non_github_pages_ip_present": false,
"is_pages_domain": false,
"is_served_by_pages": true,
"is_valid": true,
"reason": null,
"responds_to_https": true,
"enforces_https": true,
"https_error": null,
"is_https_eligible": true,
"caa_error": null
},
"alt_domain": {
"host": "www.example.com",
"uri": "http://www.example.com/",
"nameservers": "default",
"dns_resolves": true,
"is_proxied": false,
"is_cloudflare_ip": false,
"is_fastly_ip": false,
"is_old_ip_address": false,
"is_a_record": true,
"has_cname_record": false,
"has_mx_records_present": false,
"is_valid_domain": true,
"is_apex_domain": true,
"should_be_a_record": true,
"is_cname_to_github_user_domain": false,
"is_cname_to_pages_dot_github_dot_com": false,
"is_cname_to_fastly": false,
"is_pointed_to_github_pages_ip": true,
"is_non_github_pages_ip_present": false,
"is_pages_domain": false,
"is_served_by_pages": true,
"is_valid": true,
"reason": null,
"responds_to_https": true,
"enforces_https": true,
"https_error": null,
"is_https_eligible": true,
"caa_error": null
}
}

Empty response

Media type application/json
Empty Object

An object without any properties.

object
Examples
Example default
null

Custom domains are not available for GitHub Pages

Resource not found

Media type application/json
Basic Error

Basic Error

object
message
string
documentation_url
string
url
string
status
string
Example generated
{
"message": "example",
"documentation_url": "example",
"url": "example",
"status": "example"
}

There isn’t a CNAME for this page