Host an HTML or JavaScript game on WordPress

Vanilla HTML, JavaScript, and canvas or WebGL games run as-is on WordPress — zip the folder, drop it in, pick a URL. No build step, no FTP, no code.

A plain front-end app — handwritten HTML, JavaScript, and assets, or a canvas/WebGL game — is the easiest thing to host with App To Page. There’s no build step and usually nothing to configure. Zip it, drop it in, and it’s live.

Use relative asset paths

The only thing to check is how your index.html links to its files. Use relative paths and your game works at any URL:

<link rel="stylesheet" href="style.css" />
<script src="game.js"></script>
<img src="sprites/player.png" />

Avoid leading slashes like /style.css, which assume the file lives at the root of your domain. Your game will live at your-site.com/your-game, so a leading slash points to the wrong place.

Already have root-absolute paths? Don’t worry — App To Page rewrites them for you on upload. Relative is just the cleanest starting point.

Zip it and drop it in

  1. Make sure index.html is at the top level of your folder.
  2. Zip the folder’s contents (so index.html is at the top of the archive, not inside a subfolder).
  3. Go to App To Page » Apps and drop the .zip on the dropzone.
  4. On the Confirm your app card, pick a URL like snake, choose who can view it, and tick the trust checkbox. Click Create draft.
  5. Click Preview to play-test it privately, then Publish.

Your game is live at your-site.com/snake, running on its own with none of your theme’s styles bleeding in. For the full walkthrough with screenshots, see Deploy your first app.

What’s supported

App To Page serves the file types games actually use, with the correct content types — including:

  • wasm — for engines compiled from C/C++/Rust (Unity, Godot, Emscripten).
  • Audiomp3, ogg, wav.
  • Fontswoff, woff2, ttf.
  • 3D formatsstl, glb, gltf.

Hashed asset files are cached aggressively, so repeat visits load fast, while your entry HTML is revalidated on each load — which means updates show up without players having to hard-refresh.


Frequently asked questions

Can you put a browser game on WordPress?

Yes. If your game runs from static files (HTML, JavaScript, and assets), App To Page serves it at a URL on your WordPress site — no build step and no separate game host.

Do Unity or Godot WebGL exports work?

Yes. Those exports are static files plus a wasm build, and App To Page serves wasm with the right content type. Export to a folder with an index.html, zip the contents, and upload.

Does my theme affect the game?

No. Your game renders standalone at its URL, exactly as it runs locally. Your theme and the rest of your site are untouched.

My game loads but assets are missing. Why?

Usually an asset referenced with an absolute path, or a file left outside the folder you zipped. Make sure every asset is inside the archive and referenced relatively. See Troubleshooting.