Skip to main content
07 / Reference · 7.2

Site settings

Every field PATCH /api/sites/<id> takes, with its allowed values, default, effect and who may change it.

Type
Reference
Version
a7d92ba
Last verified
2026-10-10

PATCH /api/sites/<id> changes one or more settings of a site. Every field is optional, only the fields present change, and null counts as absent. The body is JSON (Content-Type: application/json).

Fields​

Who is the role that may send the field: manage means an administrator, or an operator assigned to the site.

FieldTypeSitesAllowed valuesDefaultEffectWho
aliaseslist of stringsproduction (not staging)plain host names, not the domain, no duplicates, at most 50, none another site's; [] removes themnonethe names the site answers for besides its domain; a Let's Encrypt certificate is reissued for new namesadministrator
profilestringallbalanced, commerce, maximumcommerce for WooCommerce, else balancedpage-cache lifetime, bypass rules, PHP process managermanage
cache_enabledbooleanalltrue, falseon, except static and reverse proxyturns the page cache on or offmanage
cache_ttl_secintegerall0 to 315360000how long a page stays cached; 0 is the profile's lifetimemanage
php_workersintegerall0 to 640the maximum number of PHP workers; 0 sizes them automaticallymanage
hstsbooleanalltrue only with a certificate valid for at least another 14 daysoffadds Strict-Transport-Security: max-age=31536000manage
php_versionstringwith PHPan installed version; the site's current version passes even when no longer installedchosen at creationthe site's PHP-FPM versionmanage
memory_limit_mbintegerwith PHP64 to 4096256, 512 for WooCommercePHP's memory_limitmanage
upload_max_mbintegerwith PHP1 to 204864upload_max_filesize and post_max_sizemanage
max_execution_secondsintegerwith PHP10 to 600120max_execution_time; a request's real limit is this plus 10 s, at least 120 smanage
public_rootstringall but reverse proxyempty, or a relative path of segments made of letters, digits, - and _, with no symbolic link or file along the pathpublic for Laravel, else emptythe folder served, inside the live release (current/<public_root>)manage
proxy_upstreamstringreverse proxyan http or https URL with no credentials, query or fragment; stored normalisedchosen at creationwhere requests goadministrator
object_cachebooleanWordPress, WooCommercetrue, falseoffinstalls and turns on the APCu object cache, or turns it offmanage

Any other field in the body makes the request malformed.

Profiles​

ProfileCache lifetimeServed stale for up toPHP process manager
balanced (Balanced)600 s7200 sondemand, except WooCommerce
commerce (Commerce)300 s3600 sdynamic
maximum (Maximum)86400 s3 daysdynamic

A cache_ttl_sec other than 0 replaces the profile's lifetime.

PHP workers​

With php_workers at 0, the workers' maximum is the site's memory divided by 80 MB, at most three per CPU. With a value, it is that value. Either way the result stays between 2 and 64.

The site's memory is a quarter of the server's memory shared among the sites, at least 160 MB.

The budget check runs when the request carries php_workers or memory_limit_mb and the site's number of workers, after the change, is above 0: workers × memory limit (256 MB, or 512 for WooCommerce, when the limit is not set) may not exceed the server's memory. "allow_over_budget": true skips the check; only an administrator may send it.

Answers​

CodeWhen
202{"site": …, "task": …}, plus "warnings" when there is something to know
400malformed body or unknown field; no field; a value against its rule, an alias another site holds included ({"error": …, "fields": {<field>: <message>}}); PHP budget exceeded
403aliases or proxy_upstream (with fields), or allow_over_budget, from anyone but an administrator
404the site does not exist or is out of an operator's reach
409hsts: true without a certificate valid for at least another 14 days
503the panel is restarting: try again in a moment

The change is saved at once and applied by the Site settings task. If the task fails, the panel puts back the previous values of the fields no later request changed.

Next step​

Change a site's settings, step by step.

Was this page useful?
Edit this page ↗