---
title: "Behind the build: 2025's BFCM globe in a pinball machine 🌎🕹️"
description: "Shopify's 2025 BFCM live globe was embedded in a browser pinball game built with three.js and react-three-fiber, streaming real merchant orders via server-sent events and reacting to sales milestones and first sales."
url: "https://swe.quest/articles/behind-the-build-2025-s-bfcm-globe-in-a-pinball-machine-31ac98f2441d854c"
canonical: "https://shopify.engineering/2025-bfcm-live-globe"
source: "Shopify Engineering"
published: "2025-12-03"
difficulty: "medium"
kind: "Case study"
reading_minutes: 16
tags: ["frontend","react","performance","gaming","realtime"]
---

# Behind the build: 2025's BFCM globe in a pinball machine 🌎🕹️

A post on [Shopify Engineering](https://swe.quest/sources/shopify.md), published 2025-12-03, 16 min read, Case study. Original: [https://shopify.engineering/2025-bfcm-live-globe](https://shopify.engineering/2025-bfcm-live-globe)

## Summary

Shopify's 2025 BFCM live globe was embedded in a browser pinball game built with three.js and react-three-fiber, streaming real merchant orders via server-sent events and reacting to sales milestones and first sales. The team switched from Rapier 3D to Rapier 2D physics for mobile performance, faking ramps with sensors that toggle collider sets, and cut the physics step from 2ms to about 0.2ms even with six balls and continuous collision detection. Lighting was baked in Blender with MeshBasicMaterials. The 85 dynamic table lights are rendered via an emissive texture plus a mask texture encoding light IDs in the red channel. A shader plays 128x32 dot-matrix sprite sheets, and AR support took about 100 lines with @react-three/xr.

Written by swe.quest, not by the author.

**Difficulty:** Medium: assumes a working developer; shows how it is built or done

## Topics

- [Frontend](https://swe.quest/tags/frontend.md) (Web & mobile)
- [React](https://swe.quest/tags/react.md) (Web & mobile)
- [Performance engineering](https://swe.quest/tags/performance.md) (Reliability & operations)
- [Games](https://swe.quest/tags/gaming.md) (Domains)
- [Real-time systems](https://swe.quest/tags/realtime.md) (Backend & APIs)

## Prerequisites

- three.js basics
- game physics engines
- shaders

## Keywords

three.js, react-three-fiber, Rapier, zustand, server-sent events, @react-three/xr, Blender, BFCM

## Related posts

- [How We Built the BFCM 2023 Globe](https://swe.quest/articles/how-we-built-the-bfcm-2023-globe-509c84faf6998eb6.md): Shopify Engineering · 2024-10-30 · Medium · 17 min read · Frontend, Performance engineering, React
  Shopify's BFCM 2023 live-orders globe was built with Three.js and React-three-fiber, and most of its effects are drawn in single instanced draw calls.
- [Coding the stars - an interactive constellation with Three.js and React Three Fiber](https://swe.quest/articles/coding-the-stars-an-interactive-constellation-with-three-js-and-react-three-5ccc7dd966bd420d.md): Supabase · 2023-08-04 · Medium · 10 min read · React, Frontend, JavaScript
  Supabase built its Launch Week 8 visual as an animated constellation where each user ticket signup becomes a star particle tracing an "8" shape, using Three.js via React Three Fiber in Next.js.
- [How We Built Shopify Party](https://swe.quest/articles/how-we-built-shopify-party-138ce85fd801204a.md): Shopify Engineering · 2022-06-14 · Medium · 13 min read · Games, Real-time systems, Performance engineering, WebAssembly
  Shopify Party is a browser-based multiplayer 3D hangout space built in Unity WebGL with Normcore for networking.
- [Bun 1.3](https://swe.quest/articles/bun-1-3-14b383a02cc8854f.md): Bun · 2025-10-10 · Medium · 63 min read · JavaScript, Runtimes & VMs, Databases, Frontend, Developer tools
  Bun 1.3 turns Bun into a full-stack JavaScript runtime. Bun.serve() now includes a built-in frontend dev server with HMR and React Fast Refresh, parameterized routing, and standalone executables for full-stack apps.
- [The Future of React Native Graphics: WebGPU, Skia, and Beyond](https://swe.quest/articles/the-future-of-react-native-graphics-webgpu-skia-and-beyond-c599058475fc1e90.md): Shopify Engineering · 2025-06-20 · Easy · 7 min read · React, Mobile, Performance engineering
  React Native WebGPU, built on Google's Dawn, lets React Native apps run Three.js, React Three Fiber, TSL shaders, ComputeToys compute shaders and TensorFlow.js on Metal (iOS) and Vulkan (Android) with no changes, which collapses the separate OpenGL and Metal backends into one.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
