An HTML5 game is a game that runs directly in a web browser using only technology built into the browser. No plugin and no installation. If you have played a game on a website in the last several years, it was almost certainly one.
What HTML5 means
HTML is the language web pages are written in. HTML5 is the name of a major revision, finalized as an official standard in 2014 after years of gradual adoption, which added features for rich, interactive content.
In everyday use, "HTML5" is shorthand for a group of web technologies working together.
| Technology | Job in a game |
|---|---|
| HTML | The structure of the page |
| CSS | How menus and interface look |
| JavaScript | The logic: the part that makes a game a game |
| Canvas | Drawing 2D graphics |
| WebGL | Fast 2D and 3D graphics using the graphics chip |
| Web Audio | Sound effects and music |
| WebSockets | Real-time multiplayer |
| WebAssembly | Running code from other languages at high speed |
| Local storage | Saving progress on the device |
So an "HTML5 game" is really a game written mostly in JavaScript, or compiled to WebAssembly, that uses these features together.
What it replaced
Before HTML5, browsers could do little alone. Games on the web depended on plugins, extra software installed into the browser.
| Plugin era | HTML5 era | |
|---|---|---|
| Main technology | Flash, also Java applets, Shockwave and Unity Web Player | Built into every browser |
| Installation | A plugin to install and keep updated | None |
| Phones | Mostly unsupported | Fully supported |
| Security | Frequent vulnerabilities | Inside the browser's sandbox |
| Who controls it | One company per plugin | Open standards agreed by browser makers |
| Updates | Plugin and game separately | The game updates each time you load it |
The turning point was the phone. The iPhone never supported Flash, and as browsing moved to phones, a web that depended on plugins could not keep working. Adobe ended Flash at the close of 2020.
The main milestones:
| Year | Event |
|---|---|
| 2004 | Apple introduces the canvas element in Safari |
| 2010 | Steve Jobs publishes "Thoughts on Flash", backing HTML5 instead |
| 2011 | WebGL 1.0 is released. Angry Birds appears as a web game for Chrome |
| 2012 | Cut the Rope is released as an HTML5 game |
| 2013 | Cookie Clicker and GeoGuessr launch |
| 2014 | 2048 spreads across the web. HTML5 becomes an official standard |
| 2015 | Agar.io starts the ".io" wave of multiplayer browser games |
| 2017 | WebAssembly ships in all major browsers |
| 2018 | Krunker puts a full first-person shooter in a tab |
| 2020 | Flash is retired |
| 2021 | Wordle launches |
| 2023 | WebGPU arrives in Chrome |
Why it matters for games
- No plugin. The game runs in any modern browser as it is.
- Phones and computers alike. The same game runs on a laptop, a tablet and a phone.
- Instant play. Open a link and it starts.
- Open standards. Every major browser supports them, and no single company can switch them off.
- Easy to update. The developer changes the files on the server, and every player has the new version on the next visit.
- Easy to share. A game is a link.
Early HTML5 games were simple and for a while compared poorly with the best Flash games. That has changed. Browsers now run JavaScript very quickly, WebGL gives access to the graphics chip, and WebAssembly lets code from other languages run at close to full speed. Games built with Unity, Godot and other engines can be exported for the web, and as a demonstration, programmers have ported classics such as Doom 3 to run in a tab.
Modern web games can also do things that once needed an app.
| Capability | What it enables |
|---|---|
| Real-time multiplayer | Arena games and shooters with dozens of players |
| Controller support | Play with an Xbox or PlayStation controller |
| Vibration | Feedback on phones |
| Full screen and pointer lock | Proper mouse aiming in shooters |
| Offline support | Games that keep working after the first visit |
| Home screen install | An icon and full-screen launch, like an app |
| Touch input | Multi-finger controls on phones and tablets |
The limits
| Limit | Detail |
|---|---|
| Download size | Everything loads over the internet, so games are kept compact, typically a few to a few tens of megabytes |
| Performance | Close to an installed game for most purposes. Not equal for the most demanding 3D |
| Memory | Browsers cap how much a tab can use, lower on phones |
| Browser differences | Developers test on several. Safari on iPhone has its own quirks around sound and full screen |
| Audio rules | Sound cannot start until the player touches the page |
| Storage | Saves live in the browser and can be cleared |
| Background tabs | Paused or slowed to save power |
How to tell, and how to get the best from one
Any game that plays in your browser today without asking you to install a plugin is an HTML5 game. There is nothing you need to do to enable it.
- Keep your browser updated. Each release makes games faster.
- Check that hardware acceleration is on in the browser's settings.
- Tap or click the game once to allow sound.
- Use full screen.
- Close spare tabs on a device with little memory.
- Add the game to your home screen on a phone if you play it often.
- Use a normal window, not a private one, so progress is kept.
For players the result is simple. A link is all you need, on nearly any device.