Hosting your game

Games on this site are played on servers run by their creators. You make the game here, then run the Brickyard server template on your own computer, VPS or home server. Players find your server on the game page and join from their browser.

How it fits together

  1. Build and publish. Edit your game in Studio (or upload a .bky) and press Publish.
  2. Copy the config. On Create, open your game's Servers panel. Every game already has its own host key, so the config is ready to paste.
  3. Run the server. It downloads your published game and checks in every 30 seconds, adding itself to the game's page. You never add servers by hand.
  4. Players join. When they press Play, this site gives them a one-time ticket. Your server confirms the ticket with the site, so it knows each player's username without ever seeing passwords.

When you publish a new version, running servers pick it up within a couple of minutes and tell connected players to rejoin.

1. Get the template

Download the server template and unzip it anywhere. It needs Node.js 18 or newer.

Download server template (.zip)

cd brickyard-host
npm install
cp config.example.json config.json

2. Fill in config.json

Copy the ready-made config from your game's Servers panel and save it as config.json.

{
  "HUB_URL": "",
  "HOST_KEY": "bkyh_…",
  "PUBLIC_URL": "https://play.example.com",
  "PORT": 7777,
  "MAX_PLAYERS": 20
}

3. Start it

npm start

You should see Registered with hub. Your server appears on the game page as Server #1 (the next one is #2, and so on). Stop it with Ctrl+C and it disappears straight away; if it crashes, it drops off within 90 seconds. Run as many as you like with the same key: each one is listed separately.

Server numbers are the only thing players see, so the name you give a server is just for your own logs.

4. Make it reachable over HTTPS

Browsers block insecure connections from secure pages, so players need to reach your server at an https:// address. Any of these work:

The template also includes a Dockerfile if you prefer containers.

What the server does

Scripts run on each player's device. Use net.send / net.on in your scripts to keep shared things (like a door or a scoreboard) in sync between players.

Keys and safety