How Chrome Dino Was Built (Inside the Code)

How Chrome Dino was built is one of the better-documented stories in browser-game history because the game is open source. The Chrome Dino game — also called T-Rex Runner, also reachable at chrome://dino, also playable any time you lose your network connection in Chrome — was designed by Sebastien Gabriel inside Google in 2014. It shipped under the BSD-3 license. The canonical mirror lives at github.com/wayou/t-rex-runner. The team codenamed it “Project Bolan” — a reference to T. Rex band frontman Marc Bolan.
Key takeaways
- Chrome Dino was designed in 2014 by Sebastien Gabriel, a Google designer.
- The internal project codename was “Project Bolan,” after Marc Bolan of T. Rex.
- The source is open under the BSD-3 license; the canonical fork is github.com/wayou/t-rex-runner.
- The game is a single-file JavaScript runner — no framework, no asset pipeline beyond a sprite sheet.
- It triggers on Chrome’s network-error page and is also reachable at chrome://dino.
Why it exists
The Chrome team wanted something playful to soften the experience of a network error. The “no internet” page in Chrome was originally a static “Unable to connect” message. Gabriel and the design team replaced it with a small pixel illustration of a T. rex against a desert horizon, with an instruction to press space to play. The game underneath that instruction is the runner you’ve probably played dozens of times.
The choice of a dinosaur is the design joke. A T. rex is a thing from a long-ago time. The page is showing because you’ve gone back to a long-ago time — the pre-internet era. The pun is small but deliberate, and it’s a useful frame for the whole project: a piece of Easter-egg interaction design that takes itself just seriously enough to be good, but not so seriously that it overshadows its host page.
Who Sebastien Gabriel is
Sebastien Gabriel is a designer who worked at Google during the period the Chrome Dino was developed. He has talked publicly about the project in blog posts and conference appearances. His work on the game included the pixel-art sprites, the visual design of the runner page, and the broader direction of the Easter egg experience. The engineering side of the implementation involved other Chrome team members, but Gabriel is the credited designer.
The pixel-art style of the dinosaur, the cactus, the pterodactyl, the cloud, and the moon is a deliberate aesthetic choice. The art is faithful to early-1980s sprite work — small palette, clean silhouettes, no anti-aliasing. The visual identity is part of why the game has aged so well. Pixel art is the one style that doesn’t look dated, because it was always pixel art on purpose.
The codename
The internal codename “Project Bolan” is a reference to Marc Bolan, the frontman of the band T. Rex (the 1970s glam-rock band, not the dinosaur). The pun is one layer deeper than the dinosaur joke on the page — the team named the project after the band that the dinosaur shares a name with. The codename has been confirmed in interviews and blog posts from Google designers.
This kind of internal joke matters because it’s a sign of how the team thought about the project. Easter eggs that take themselves seriously are rare. Easter eggs that are written with a nested pun in the project name are written by people who care about the texture of the work, not just the deliverable.
The architecture
The Chrome Dino game is implemented as a single JavaScript file with a sprite sheet image. The main file is roughly two thousand lines of vanilla JavaScript, no framework. The class hierarchy is straightforward: a Runner class manages the overall game loop; a Trex class manages the dinosaur sprite, its jumping and ducking states, and its collision box; an Obstacle class spawns and animates cacti and pterodactyls; a Horizon class manages the scrolling ground and the sky.
The game loop is a requestAnimationFrame loop. Each tick: update positions, check collisions, render to canvas. The collision detection is rectangle-based with multiple sub-rectangles per sprite, which is what makes the dino’s collision feel fair (a ducking dino has a different collision box than a running dino, etc.). The render path draws directly to a 2D canvas from the sprite sheet.
There is no audio in the original game. There is no networking. There is no save state — every run starts at zero. The simplicity is the point. The game has to load instantly because it appears on a network-error page, where loading time and dependencies are exactly the things that can’t be relied on.
The open source release
The Chrome Dino code is open source under the BSD-3 license. The canonical public mirror is at github.com/wayou/t-rex-runner — a fork by GitHub user wayou that extracts the runner from the Chromium repository and makes it embeddable on any web page. That fork is what most independent sites (including this one) base their playable versions on.
The BSD-3 license is permissive. It allows redistribution and modification with attribution. That’s why there are so many Chrome Dino clones around the web — building one is a matter of taking the wayou fork, dropping it into a page, and calling Runner.config. Some clones add features (auto-jump, infinite mode, themes, character swaps); others just embed the original.
The infinite-jump bug
The original code has a documented edge case that lets a player chain jumps indefinitely under certain timing conditions. It’s not a feature, but it’s not patched either — the Chrome team has left it in place. There’s also a console trick — calling Runner.instance_.gameOver = function(){} in the browser DevTools — that disables the game-over state and lets the player run indefinitely. Both are signs of how lightly the game is policed by its own creator.
These quirks are part of the game’s character. A heavily polished and patched Easter egg would feel different. The fact that small bugs and console tricks survive in the live version makes the game feel like the side project it actually is — a thing the Chrome team made for fun and have been content to leave alone.
What it teaches
The Chrome Dino game is a study in the value of constraints. It has to run with no network. It has to load in milliseconds. It has to be playable with one input. It has to fit inside a browser error page without overwhelming it. Every design choice — the pixel art, the minimal sprite count, the rectangle-based collision, the single canvas, the absence of audio — is downstream of those constraints.
The lesson for any browser-game developer is that constraints sharpen design. The Chrome team did not set out to make a beloved game. They set out to make a useful, charming addition to an error page. The fact that it accidentally became one of the most-played games in the world is a function of the discipline that went into its scope. For a deeper look at the source itself, see our Chrome Dino source code explainer, and our Chrome Dino history traces the game from 2014 to 2026.
Frequently asked questions
Who designed the Chrome Dino game?
Sebastien Gabriel, a designer at Google in 2014, led the design of the Chrome Dino Easter egg. The engineering implementation involved other Chrome team members; Gabriel is the credited designer.
Why is the Chrome Dino codename “Project Bolan”?
The codename references Marc Bolan, the frontman of the 1970s glam-rock band T. Rex. The pun layers on top of the existing dinosaur joke on the network-error page.
Is the Chrome Dino game open source?
Yes. The game is released under the BSD-3 license. The canonical extracted source is at github.com/wayou/t-rex-runner. The original lives inside the Chromium repository.
What language is Chrome Dino written in?
Plain vanilla JavaScript, with a sprite sheet for art. No framework, no build tooling, no audio. The whole game is roughly two thousand lines of code rendered to a 2D canvas. The Dinosaur Game Wikipedia entry covers the credits and history.
How does the Chrome Dino game handle collisions?
The game uses rectangle-based collision detection with multiple sub-rectangles per sprite. A ducking dino has a different collision shape than a running dino, which is part of why the game feels fair even at high speeds.
The takeaway
How Chrome Dino was built is a story about a small team making something delightful inside a giant browser. Sebastien Gabriel and the Chrome team turned a network-error page into one of the most-played games in the world, and they did it with a sprite sheet, two thousand lines of JavaScript, and a codename that doubles as a band reference. The game is still here, still open source, still playable any time the network drops. Try the T-Rex Runner right here at the top of this page, no error needed.








