How to make a game with AI, step by step

By GamesByAI · Published · Updated · 22 sources

On this page

Making a game with AI is basically a loop. You describe a change, run the game, play it and fix what feels wrong, then go around again. Start with one mechanic you can actually play, and keep each next change small enough to check in a single round.

Pick by who keeps the files

If you want to own the files and choose the engine, take a coding agent. A browser builder is the better pick when you want a first version with no setup.

A coding agent works in a project folder on your computer, while a browser builder runs on its maker’s site and gives you a game to edit and publish. Either way, you start from a plain-language description of the game.

What it takes Coding agent Browser builder
Examples Claude Code, Codex, Cursor Rosebud, Lovable, Bolt
You need A computer, a project folder and an account A browser and an account
You handle The engine, the files and the hosting The idea and the edits; the builder handles the stack
Good for Any browser game, and a game you keep editing A first playable version with no setup

As of September 2026, the main ones work like this.

  • Claude Code runs in a terminal, in VS Code and JetBrains, as a desktop app and in the browser. Most of those need a Claude subscription or a Console account (Claude Code docs).

  • Codex is included in every ChatGPT plan, Free included, with usage limits that vary by plan (Codex pricing).

  • Rosebud writes the code and makes the art and sound for a game from your description, on Three.js. It’s free to start, and its paid plans add commercial rights (Rosebud).

  • Lovable and Bolt build general web apps from a chat (Lovable docs, Bolt).

For exports, publishing limits and rights, see best AI game makers.

Most games we list name a coding agent

Claude Code, Codex or Cursor is named on 70% of the games we list, and Three.js is the most common engine.

The counts are current as of November 14, 2026. Creators name the tools themselves, mostly in the jam submission form, and we don’t independently verify those tool attributions. The jam rules also required at least 90% of the code to be written by AI.

Tool named by the creator Route Games
Claude Code Coding agent 224 (38%)
Codex Coding agent 101 (17%)
Cursor Coding agent 106 (18%)
Google Antigravity Coding agent 20
Claude app Chat app 28
ChatGPT Chat app 19
Gemini app Chat app 10
Grok app Chat app 5
Bolt Browser builder 6
Lovable Browser builder 9

Creators name a bunch of other tools too, like GitHub Copilot and Kiro, and you’ll find them on the tools page with their game counts.

Recorded engine Listed games
Three.js 322 (55%)
No engine stated 151
Phaser 27
Canvas 37
PixiJS 14
Godot 16
Support recorded Listed games
Mobile support listed 293 (50%)
Online multiplayer 200 (34%)

Keep in mind that this sample leans a lot on one jam, since 70% of the games are its entries. Its rules allow any engine but recommend Three.js (jam rules), and its press page says multiplayer is preferred but not required (press page).

Even so, you can see the pattern pretty clearly. It’s a JavaScript game that runs in a browser, and often on a phone too. You can look through the entries in the Vibe Jam 2026 hub or the top rated games.

The steps go from a short brief all the way to a published page.

1. Write a one-paragraph brief

Write down the genre, the camera, the controls on desktop and phone, what one run looks like and how it ends. Add technical limits too, like one web page and Three.js.

The idea itself should fit in a sentence. Our catalog’s tagline for Floppy Brawler is “Fight ragdoll-style opponents in a wobbly, physics-driven brawler.” That’s pretty much the right size.

Claude Code’s best-practices page suggests letting the agent interview you and write a spec before it builds (best practices). There’s an interview prompt you can copy in 10 prompts to copy and adapt.

Then save the brief where the agent will read it. It’s a bit annoying, but as of September 2026, each tool looks in its own place.

  • Claude Code reads a CLAUDE.md file at the start of every session (best practices).

  • Codex reads AGENTS.md files before it starts work (Codex docs).

  • Cursor applies project rules from .cursor/rules or AGENTS.md (Cursor docs).

2. Choose an engine

Three.js is the most common engine in our data. It’s an open-source JavaScript library for 3D graphics in the browser, under the MIT license (Three.js, GitHub).

For 2D, Phaser is an open-source HTML5 game framework (Phaser on GitHub) that you can load from a CDN or install with npm (Phaser docs). If you want a gentle way in, Phaser with AI installs the agent skills that ship with Phaser 4 and builds a small game with them.

Godot is another option. It exports to the web with WebAssembly and WebGL 2, but Godot 4 currently can’t export C# projects to the web (Godot docs).

Coding agents write GDScript like any other code, and a Godot MCP server lets them run the project and read its errors (MCP servers for game development). You can see games on each engine in the Three.js, Phaser and Godot hubs.

For a worked Godot example, Claude Code and Godot: build a browser game starts with an empty project and ends with a Web export you can upload or embed, with rules for Codex too.

3. Build the smallest playable version first

Ask for one screen, one control scheme and one goal, and run it before you ask for anything else. Then add one feature per request, like a hazard, then a score, then a second level.

Claude Code’s guidance is to explore first, then plan, then code, and to skip the plan when you could describe the change in one sentence.

4. Give the agent a way to check its work

An agent can’t tell whether its work is right without something to check it against. That’s why Claude Code’s docs advise giving it a check it can run, like tests, a build or a screenshot (best practices).

For a game, that can be a build command, a few tests for the rules (score, collisions, win and lose) and a screenshot of the running page. Then you play it yourself.

The same page warns about plausible-looking code that misses edge cases, and it says “If you can’t verify it, don’t ship it.”

Playtesting games with AI shows how to let the agent play the game itself, with a test hook and a smoke test.

5. Save progress with git

Commit each working version. Claude Code does save handy checkpoints of its file edits, but its docs say checkpoints aren’t a replacement for git, and they don’t capture changes made through shell commands.

6. Test on a phone

Test touch controls, screen size and speed on a real phone, because a build that works with a keyboard can’t tell you whether a thumb can reach the jump button. How to make a mobile game with AI covers touch controls, screen fit and phone testing.

While you build, serve the game from a local web server, since Phaser’s docs warn that pages opened from disk hit browser security limits when they load images and audio.

7. Publish and share

As of September 2026, GitHub Pages serves HTML, CSS and JavaScript files straight from a repository (GitHub Pages docs). On itch.io, an HTML5 game is a zip file with an index.html, and you choose whether it embeds in the page or launches full screen (itch.io docs).

Vibe Jam 2026 required games to run on the web with no login or signup, which is a good rule to borrow anyway. Where to publish a browser game compares itch.io, CrazyGames, Poki and the stores. And once you’ve made something playable, you can submit it to GamesByAI.

Keep the next change small enough to test

A few habits really help here. Clear the session when failed fixes pile up, play every change, ask for feel by name and grow the scope one feature at a time.

  • The session fills with failed attempts. Claude Code’s docs advise clearing the session after two failed corrections and starting again with a sharper prompt.

  • Nobody checked the output. Play every change before you build on it, and give the agent a check it can run, as in step 4.

  • It works but feels flat. A prompt that describes mechanics gets you mechanics, because feel comes from small timings nobody asked for. Game feel with AI lists twelve to ask for by name.

  • Too much at once. Online multiplayer and Three.js are common in our catalog, but most of those games were built in a one-month jam, so get the core loop working first.

Tune the feel and test another round

Getting from working to actually fun is what game feel with AI is for, and playtesting games with AI gets you from fun to stable. Vibe coding a game covers prompts and pacing, and selling AI-made games covers store rules and ownership.

If you’ve picked a tool, Claude Code game development, Codex game development and Cursor game development take one agent at a time. Make games with Gemini and make games with ChatGPT cover the Google and OpenAI routes, and best AI for game development compares the tools for the job.

For single steps in depth, there’s ten prompts to copy, game assets with AI and a mobile game with AI. And if you’re still deciding what to build and on which engine, try vibe coding game ideas, the best engine for vibe coding and how to make a 3D game with AI.

Games to look at

Questions

How to make a game with AI for free?

You can start free, as of September 2026. Codex is included in every ChatGPT plan, Cursor and Google Antigravity have free plans, and Rosebud is free to start, though its paid plans add commercial rights. Claude Code isn't part of Claude's Free plan.

Can you make a game with AI without coding?

Yes, for small games. Browser builders like Rosebud, Lovable and Bolt generate the code from a written description, and coding agents write it inside your project folder. You still playtest the game, describe what to fix and publish it.

How to make a game in Godot with AI?

Use a coding agent in your Godot project folder. It writes GDScript and edits scene files, and an MCP server like the community godot-mcp lets it run the project and read the errors. Godot exports to the web with WebAssembly and WebGL 2, but Godot 4 can't export C# projects to the web, and Three.js is more common in our catalog anyway.

How to make a game with Claude AI?

Use Claude Code, which reads your project, edits files and runs commands in a terminal, an IDE, the desktop app or the browser. For a small game, you can also ask the Claude app for an artifact and play it in the side panel. Claude Code needs a paid Claude plan, a Console account or a cloud provider.

Can you publish a game made with AI?

Yes. GitHub Pages serves static HTML, CSS and JavaScript files, and itch.io accepts an HTML5 game as a zip file with an index.html. Steam and itch.io both ask you to disclose AI-generated content, so read our guide to selling AI-made games first.

More sources

  1. claude.com/pricing
  2. cursor.com/pricing
  3. antigravity.google/pricing
  4. github.com/Coding-Solo/godot-mcp
  5. support.claude.com/en/articles/9487310-what-are-artifacts-and-how-do-i-use-them