VoxelSite ships with anDocumentation Index
Fetch the complete documentation index at: https://docs.websitestudio.app/llms.txt
Use this file to discover all available pages before exploring further.
.htaccess file that handles clean URL routing and security rules on Apache. Nginx ignores .htaccess entirely — you need to add equivalent rules to your Nginx site configuration.
Without this configuration, visiting /about will show your homepage instead of about.php, because Nginx doesn’t know to try the .php extension.
The essential fix: clean URLs
VoxelSite generates pages as PHP files (about.php, contact.php, etc.) and links to them with clean URLs (/about, /contact). On Apache, the .htaccess rewrite rule handles this automatically. On Nginx, you need to add a named location that rewrites extensionless URLs to .php.
Find the location / block in your Nginx config and replace it with:
Why not
$uri.php in try_files? Adding $uri.php as a middle argument in try_files finds the file but serves it as raw text — it bypasses the PHP handler. The named @cleanurls location with rewrite ... last does a proper internal redirect that re-evaluates against location ~ \.php$, ensuring PHP-FPM processes the file.Agent API routing
The Agent API works without this rule. The Studio router automatically detects
/agent/v1/ requests and forwards them to the Agent API router. The Nginx rewrite below is a performance optimization — it routes requests directly to the Agent API router, skipping the Studio router overhead. For most installations, the automatic fallback is sufficient.location / block:
.htaccess rule, which passes the path as ?_path=$1. For example, a request to /_studio/api/agent/v1/pages will be rewritten to /_studio/api/agent/v1/router.php?_path=pages.
Recommended security blocks
The.htaccess also blocks access to sensitive directories and files. Add these before the location / block:
Complete Nginx config example (Forge)
Here’s a complete site configuration block for Laravel Forge. Replace the site ID (3050636) with your own:
Where to edit this on Forge
Open the Nginx configuration editor
Go to Sites → your site → Nginx Configuration (the Edit button on the files panel).