# HydePHP guide

Source: https://docs.fortrabbit.com/guides/more/hyde
Reviewed: 2026-09-04

> HydePHP is a static site generator built on Laravel Zero. It compiles Markdown and Blade to plain HTML, which fortrabbit serves from the _site folder.


::CallOut{alert}
This is work in progress. The software template has not been exercised on a real app yet.
::

## What running Hyde here means

Hyde is a static site generator, not a CMS. `php hyde build` reads Markdown and Blade and writes plain HTML into a folder called `_site`. Nothing PHP answers a request afterwards — PHP only runs during the build.

That shapes the whole setup. The build happens as a [build command](/platform/deployment/build-commands) during deployment, and the [root path](/platform/settings/root-path) points at `_site` rather than at the project folder. The PHP component still has to be booked, because the build needs it.

## Versions

Hyde 2 is the current major and needs PHP 8.2 or newer, so set the [PHP version](/platform/settings/php) accordingly. Hyde 1 is still installable and has the same build command and the same output folder.

## Get ready

Have a [local PHP development environment](/integrations/local-development/intro) with PHP 8.2 or newer and Composer, plus a git repo to deploy from.

## Create an app at fortrabbit

Create a new app and pick HydePHP as software. The [software template](/platform/concepts/software-templates) behind the preset sets the root path, the build commands and the `SITE_URL` variable described below, so there is less to configure afterwards.

:BlockLink{title="Create a new app" path="/new/app"}

## Install locally



```shell
$ composer create-project hyde/hyde my-site
$ cd my-site
$ php hyde build
```

The build writes `_site`. Serve it with any static server, or run `php hyde serve` for the realtime compiler while writing.

## Keep the compiled site out of the repo

`_site` is rebuilt on every deployment, so it belongs neither in git nor in the deploy package. Add it to `.gitignore` in the project root:



```shell
# .gitignore

# Composer, installed by the build command
/vendor

# Written by `hyde build` on every deployment
/_site
```

## Deploy

Connect the repo as described in the [git deployment intro](/platform/deployment/intro), then push. Two [build commands](/platform/deployment/build-commands) run in order:



```shell
$ composer install --no-dev --prefer-dist --no-interaction --no-ansi --no-progress
$ php hyde build
```

The [root path](/platform/settings/root-path) is `_site`, so the compiled HTML is what visitors reach.

:BlockLink{title="Visit test domain" path="https://{{app-env-id}}.frbit.app" property="none"}

## Set the site URL

Hyde writes relative permalinks unless it knows the address the site is served from, and it skips the sitemap and the RSS feed entirely. Set `SITE_URL` as an [environment variable](/platform/settings/env-vars), including the protocol:



```raw
SITE_URL=https://www.my-site.tld
```

The software template presets this to the environment's main domain. Change it once a custom [domain](/platform/objects/domain) is the primary one, otherwise links keep pointing at the `frbit.app` address.

`SITE_NAME` is optional and names the site in the RSS feed and the meta tags.

## Writing content

Markdown files in `_pages`, `_posts` and `_docs` become pages; Blade views in `resources/views` provide the layout. All of it is code as far as the platform is concerned — it is committed, pushed, and compiled during deployment. There is no admin panel and nothing writes to the environment at runtime, so no [rsync](/dev/how-to/rsync) step and no writable folders to exclude.

## What a static site does not need

No MySQL component, since Hyde stores nothing. No [jobs](/platform/components/jobs) and no key-value store either. A Hyde app books PHP for the build plus storage and traffic, which is the leanest combination the platform offers.
