All posts

Page Data: Give Your Static Page a Memory

A per-page key-value store that lets any hosted HTML page collect polls, RSVPs, and guestbook entries — no backend required.

A browser page sending data cards into a small locker box

A static page has a perfect memory for what you wrote, and no memory at all for what your visitors do. A poll on a static page is decoration: people click, nothing is recorded, nobody learns anything. The usual fix is a backend — a database, an API, a server you now have to maintain. For a weekend project, that is a heavy price for a simple question.

Page Data is HTMLPUT's answer: a per-page key-value store for structured JSON, attached to any page you host. Guests — or your own scripts — write rows. You read them in History, under Data. No server, no database, no maintenance. Think of it as a locker for data on a static page, not a place to run Node.js. That distinction matters, and we will come back to it.

Three things people actually build with it

1. A poll that counts. A few buttons, one POST per vote, results you can read and export as CSV. The page stays static; the answers accumulate.

2. An RSVP or check-in. The invitation template in the Page Data catalog is the fastest start: preview it, publish it, send guests the link. They reply without logging in, and every reply lands in your History. Weddings are the classic case; workshops and meetups work the same way.

3. A guestbook or message board. Visitors leave structured entries — name, message, timestamp — and you moderate from the Data dialog: review, hide, export.

Two ways to turn it on

No code: open Page Data on the home page, try the invitation demo, and hit Deploy. HTMLPUT creates a hosted bundle page with the schema and a write token already wired into the guest form. Previews don't write to storage and don't use quota, so experimenting is free.

Your own HTML: paste or upload your page, open its Data dialog, enable storage, and copy the page write token. Then POST JSON from the browser to /api/v1/pages/{fileKey}/kv with that token. One row per submission — use a fresh key per entry, like sub_ plus a UUID.

The honest limits (read before you build)

  • Each value must fit in 10 KB of UTF-8 JSON. This is for structured rows, not file uploads.
  • New keys count toward a lifetime account quota (Free starts at 100). Soft-deleting a row does not free its slot, so design keys you won't regret.
  • Page Data does not execute server code. If you were about to paste Express into the paste box, stop — paste static HTML instead.
  • Guest writes use the page write token, never your Agent API key. The key starting with hp_live_ manages your pages; it must never appear in front-end HTML.

A static page that remembers is a different kind of page. It can ask a question on Friday and show you the answers on Monday, without you ever touching a server. Try the invitation demo first — it takes about a minute — and see what your page learns.