Get cache status
Returns the caching state of the website: whether server-side caching is enabled and whether development (cacheless) mode is on.
Returns the caching state of the website: whether server-side caching is enabled and whether development (cacheless) mode is on. Works for the main domain, addon websites, parked domains and subdomains of the account; each reports its own settings and does not inherit them from its parent website.
is_enabled is the setting changed by Toggle website cache and reflects a toggle
immediately. is_cacheless_mode_enabled is true while development mode is on; caching is then
bypassed even when is_enabled is true. Toggle cacheless mode is applied in the background,
so this flag can take a few minutes to follow it.
The domain must be the exact website name as listed on the account, without a www. prefix.
Returns 404 when the domain is not a website on the account.
API Token authentication
u123456789Domain name
mydomain.tldSuccess response
Whether server-side caching is enabled for the website
trueWhether development (cacheless) mode is on. While it is on, caching is bypassed even when
is_enabled is true. Can take a few minutes to follow a cacheless mode toggle.
falseUnauthenticated response
Error response
GET /api/hosting/v1/accounts/{username}/websites/{domain}/cache/status HTTP/1.1
Host: developers.hostinger.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"is_enabled": true,
"is_cacheless_mode_enabled": false
}Last updated
Was this helpful?