Performance defaults
The server settings every Avaloi site starts with: page cache, compression, browser caching, PHP workers, OPcache, MariaDB, and WordPress cron.
Parts of this feature are still being built. The Not yet section lists them.
Every site and environment runs in its own container with the settings below. You do not need to change them. Plan size changes the numbers marked "per plan".
Page cache
The web server keeps a copy of each page and serves it without running PHP. The x-avaloi-cache response header shows the result: HIT, MISS, BYPASS, or EXPIRED.
| Setting | Value |
|---|---|
| What is cached | GET and HEAD answers with status 200, 301, or 302 for 10 minutes, and 404 for 1 minute |
| Skipped | Signed-in users, password protected posts, commenters, carts, and checkouts (by cookie); /wp-admin, /wp-login.php, /xmlrpc.php, /cart, /checkout, /my-account; every POST; and any path you add in Tools |
| Busy pages | When a page expires, one request rebuilds it while other visitors get the previous copy. Many visitors on a cold page reach PHP once |
| PHP errors | If PHP fails or times out, visitors get the last good copy |
| Purge | WordPress clears the cache when you publish or update. Tools > Clear cache clears everything |
Query strings are part of the cache key, so /?utm_source=x is cached as its own page.
Compression
Pages, CSS, JavaScript, JSON, XML, feeds, SVG, and fonts are compressed with Brotli or gzip from 256 bytes up. Cloudflare in front of the site serves HTTP/2 and HTTP/3 to visitors and may recompress, for example with zstd.
Browser caching
The server tells browsers how long to keep static files:
| Files | Live and other Git mode environments | SFTP mode (a writable staging) |
|---|---|---|
Uploads in /wp-content/uploads/ |
1 year | 1 year |
CSS and JavaScript with a content hash in the name, such as app.3f9a1c2b.js |
1 year | 1 year |
| Other theme, plugin, and WordPress files: CSS, JavaScript, images, fonts, video, audio, PDF | 7 days | Checked on every load |
Why 7 days and not a year: WordPress adds ?ver= to theme and plugin files, and the number often stays the same when the code changes. A year would hide a deploy from returning visitors. Build tools that put a hash in the file name get the full year. In SFTP mode the browser checks each file on every load and gets a quick "not modified" answer when nothing changed, so your edits show at once.
PHP
| Setting | Value |
|---|---|
| Workers | One per PHP thread of the plan (per plan). Smaller plans start workers on demand and stop them after 30 seconds idle (10 seconds on staging). Business 2 and up keep a few warm |
| Memory per worker | The plan's PHP memory split across its threads (per plan) |
| Request time limit | 300 seconds, the same as the web server's wait |
| Slow log | Requests over 5 seconds are written to the PHP slow log |
| Worker recycling | Each worker restarts after 500 requests |
OPcache
OPcache keeps compiled PHP in memory: 128 MB, or 192 to 256 MB on larger plans (per plan). On live and other Git mode environments the code cannot change between deploys, so OPcache never checks file times, and each deploy resets it. In SFTP mode OPcache checks file times every 2 seconds, so an edit shows within 2 seconds. The JIT is off: WordPress gains little from it, and its buffer would come out of your PHP memory.
MariaDB
| Setting | Value |
|---|---|
| InnoDB buffer pool | A quarter of the PHP memory, at least 128 MB (per plan) |
| Commit durability | Every commit is written to disk before it returns. A server crash loses no orders |
| Doublewrite buffer | Off. The ZFS file system already protects every block |
| Query cache | Off. It slows writes and does not scale |
| Temporary tables | 32 MB in memory before they go to disk |
| Connections | Two per PHP thread plus 20, for cron, WP-CLI, and the Database tab |
WordPress
- WP-Cron does not run on page loads. The server runs due events every 5 minutes. Change it under Cron jobs.
- Post revisions, the heartbeat, emoji, and embeds keep the WordPress defaults. Plugins and themes rely on them.
- The page cache runs in the web server, so WordPress needs no page cache plugin and no
WP_CACHEsetting. A page cache plugin adds work without a gain.
Not built yet
- Per site choices for cache lifetimes and browser caching.
- An autoload size warning. Large autoloaded options slow every uncached page. A new site loads about 50 KB of them.
Related
Still stuck?
Email [email protected] with your site name and what you tried, or send us a message.