# hyperclay > Hyperclay (https://hyperclay.com) is a hosting platform for malleable HTML files: single > HTML documents that hold an application's interface, behavior, content and current state, > and that save themselves back to the server as their own next version. The DOM is the > database. A save is one POST of the whole serialized document, and the host answers by > writing bytes and filing a version. There is no build step, no deploy, and no place to run > server code: if a project needs custom backend logic, Hyperclay is the wrong host. This file is the complete platform reference for agents. The human-readable documentation is at https://docs.hyperclay.com/docs/overview, with the product pages at https://hyperclay.com, https://hyperclay.com/features and https://hyperclay.com/pricing. Hyperclay itself is a hosted service, not a package you install. The client library that makes a page malleable is separate and open source: ClayJS (MIT-0) at https://clayjs.com, whose own agent reference is at https://clayjs.com/llms.txt. The document format is specified at https://malleablehtmlfile.com (CC0). Accounts are paid: Personal is $6 per month or $48 per year, Maker is $15 per month or $120 per year. ## Quick start 1. Subscribe at https://hyperclay.com/pricing, pick a username, and land on `https://hyperclay.com/_/dashboard`. 2. Create an app called `notes`. It lives at `https://.hyperclay.com/notes.html`. 3. Open `https://.hyperclay.com/_/edit/notes.html` and paste a document whose `` carries `autosave` and whose `` carries ``. 4. Open the app itself. Because you own it, edit mode is on. Type into an `editable` element. Ctrl+S saves, or autosave does it for you. 5. Open the same URL in a private window. You get the plain page with no edit controls. 6. `https://.hyperclay.com/_/versions/notes.html` lists every save. `https://.hyperclay.com/_/download/notes.html?file=1` gives you the file. ## What a malleable HTML file is One `.html` (or `.htmlclay`) file contains the markup, the styles, the scripts, the content, the current state, and the controls for editing itself. Visitors get a plain static page. The owner gets edit controls, which are stripped from the copy that is written to disk, so the saved file stays clean for the next visitor. The cycle is always the same: 1. The browser loads the document. 2. If the viewer is the owner, edit mode arms and the editing controls activate. 3. Edits mutate the live DOM. The DOM is the state, so there is nothing else to persist. 4. On save, the client clones the document, strips editor-only regions from the clone, serializes it, and POSTs that text to the host. 5. The host writes it as the file and files a version. The live page is never touched by the save. The page you are editing keeps its controls. ## Get an account Signup is paid. There is no free account creation path on hyperclay.com. 1. `https://hyperclay.com/signup` (the plan-picker page) or `https://hyperclay.com/pricing` (the marketing page) starts Stripe Checkout for a tier (`personal` or `maker`) and a plan (`monthly` or `annual`). They are two different pages into the same checkout. 2. Checkout succeeds and returns to `https://hyperclay.com/_/set-password/`. 3. That page confirms the email, creates the person, and asks for a username and password (8 or more characters, checked against a 100k common-password list). 4. The account becomes `account_type: dev` and lands on `https://hyperclay.com/_/dashboard`. The username can be changed at `/_/set-username`, but only once every 30 days. Since the username is the subdomain, changing it moves every URL under it. The session is the `auth_token` cookie, valid for 30 days, apex-scoped so it rides along on every `*.hyperclay.com` subdomain. Log in at `https://hyperclay.com/_/login`, out at `https://hyperclay.com/_/logout`. The `free` tier exists in the code and governs a lapsed subscription and the end users who sign up to somebody else's multi-tenant app. It caps app creation at 10 files, with no subdomains, no custom domains and no multi-tenant apps. ## Where your files live An account is a namespace. Every app sits inside it: ``` https://.hyperclay.com/.html https://.hyperclay.com//.html ``` Folders mirror into the URL. The root of a subdomain resolves to `index.html`. Folders nest up to 5 levels; deeper returns `Maximum folder depth reached (5 levels)`. Three ways to reach one app: - **Namespace URL**, always available: `https://.hyperclay.com/.html` - **Promoted subdomain** (paid): claim `https://.hyperclay.com` for one app. The app then sits at the **root** of that hostname, not at `/.html` under it, which is the difference between a promoted subdomain and the account namespace every file already has. - **Custom domain** (paid): point your own domain at one app, with automatic SSL. Name rules, enforced in `shared/validation.js`: - Site names match `^[a-z0-9_-]+\.(html|htmlclay)$`. A name with no recognized extension gets `.html` appended. Max 255 characters. - Folder names and usernames match `^[a-z0-9_-]+$`. - No leading or trailing dash, no `--`, no Windows device names (`con`, `prn`, `aux`, `nul`, `com1`..`com9`, `lpt1`..`lpt9`). - `_` is reserved for the system-route marker and can never be claimed, for every name type, not even by a superadmin. - **Usernames and subdomains only** are additionally checked against about 666 exact reserved words (`api`, `app`, `auth`, `blog`, `www`, ...) plus 17 substring blocks: `account`, `admin`, `billing`, `folder`, `help`, `hyperclay`, `identi`, `moderator`, `owner`, `password`, `payment`, `root`, `securit`, `server`, `settings`, `system`, `user`. Site names and folder names are **not** checked against those lists, so `api.html` and a folder named `settings` are both creatable. Platform routes live under the reserved `/_/` marker, so they can never collide with a file or folder name. Older bare forms (`/edit/...`, `/save`) still route, but write `/_/`. The public marketing and legal pages on hyperclay.com itself are the exception and stay bare (`/features`, `/pricing`, `/discover`, `/signup`, `/terms`). An unknown path under `/_/` is a 404 rather than falling through to a document. ## Make a page save itself The current library is ClayJS. One script tag is the whole integration. This is what the platform's own starter templates ship: ```html My HTML App

My HTML App

``` `autosave` on `` saves after edits settle. Ctrl+S and Cmd+S always work. `clay.save()` saves on demand. The full attribute and API surface is at https://clayjs.com/llms.txt; the short version: - `editable` on an element for rich text, `editmode:contenteditable` for owner-only plain text. - `persist` on a form control to write its value into the saved HTML. - `viewmode:disabled` / `viewmode:readonly` to make a control live for the owner and inert for visitors. - `sortable="name"` for drag-to-reorder lists (the `sortable` plugin), which fires `clay:sorted`. - `clay="no-save"` for page chrome that must never reach disk, `clay="freeze"` for computed text, `clay="no-watch"` for third-party widgets. - `trigger-save` on a `