🎮ArcadeLab
🟣May 13, 2026

How do I host a Phaser game without build tools?

💡

Quick answer

Write your Phaser game as a single HTML file with all JavaScript inline. Add the ARCADELAB header at the top with libraries: phaser. Paste at arcadelab.ai/publish. ArcadeLab injects the Phaser CDN script automatically.

Phaser is built for single-file HTML games. You can drop the CDN script tag in any page and write your game inline. The official Phaser tutorials use this pattern. The friction has always been hosting — most platforms want a repo and a deploy pipeline. ArcadeLab takes the file directly.

What does the minimal setup look like?

Here's a complete, publishable Phaser game in one HTML file:

<!--ARCADELAB
title: Phaser Demo
description: A minimal Phaser scene
libraries: phaser
emoji: 🟣
color: purple
-->
<!DOCTYPE html>
<html>
<head>
  <style>body { margin: 0; background: #000; }</style>
</head>
<body>
  <script>
    const config = {
      type: Phaser.AUTO,
      width: 800,
      height: 600,
      scene: {
        create() {
          this.add.text(400, 300, 'Hello Phaser', { color: '#fff' })
            .setOrigin(0.5);
        }
      }
    };
    new Phaser.Game(config);
  </script>
</body>
</html>

That's the entire game. Note: no <script src="https://...phaser.min.js">. ArcadeLab injects it for you because you listed phaser in the header.

How do I add assets like sprites and audio?

ArcadeLab's sandbox blocks network requests, so you can't load images or audio from external URLs. Two options:

  • Generate procedurally: use Phaser's add.graphics() to draw shapes at runtime, or build sprites with code.
  • Inline as base64 data URIs: encode small PNGs or audio clips as base64 and load them with this.textures.addBase64().

For AI-generated games, procedural assets are usually easier. Ask the AI to draw sprites with primitives instead of asking for image files.

How do I tell my AI assistant to make a Phaser game for ArcadeLab?

Share this with your AI:

"Make a Phaser game as a single self-contained HTML file. Don't include the Phaser CDN script tag — ArcadeLab loads it. Put an <!--ARCADELAB> header at the top with libraries: phaser. All JS inline. No fetch, no external assets. Generate sprites procedurally. Keep it under 500KB."

Or just point the AI at arcadelab.ai/for-ai — that page is a complete briefing.

Why not just use itch.io or GitHub Pages?

You can. itch.io supports HTML5 games well, but requires an account, a project page setup, and uploading a zip. GitHub Pages needs a repo and DNS. ArcadeLab is the fastest path: paste the file, get a URL. See ArcadeLab vs itch.io vs Glitch vs GitHub Pages.

Ready to publish? Paste your HTML file and get a URL.

🚀Publish your thing

Related guides