Back to project foundations
Reference project

Phaser

JavaScript/TypeScript framework for 2D browser games with scenes, input, animation and physics.

Why we recommend it

Phaser is a practical starting point for a playable 2D loop with sprites, tilemaps and a score or timer. Official templates let you choose the surrounding frontend and bundler without designing the game infrastructure from scratch.

When to choose it

  • Platform, puzzle, card and arcade games for desktop and mobile browsers.
  • Small web games embedded in an existing web product.

What to consider

  • This is a 2D framework. Native packaging uses additional tools and does not follow automatically from a web build.
  • Pin the Phaser major version and matching examples; scene, renderer and physics APIs can differ between releases. Assets and game-specific systems remain your work.

Start with this project

Use the official create-game guide to generate a separate project and select a JavaScript or TypeScript template. Implement preload, a scene, keyboard/touch input, collision and a restart; inspect the generated scripts before running them.