Learn to build marker-based augmented reality experiences that run in any modern mobile browser
Let's start by setting up our development environment:
Include the required libraries in your HTML head section:
Add a marker and your first 3D object inside the a-scene tag:
Browsers block camera access on file URLs. Set up a local HTTP server:
Then open your phone's browser to:
The 3D object should track perfectly with the marker movement, creating an immersive AR experience right in your browser!
Replace the basic box with sophisticated glTF models:
You've successfully created a marker-based AR experience using A-Frame and AR.js that works in any modern mobile browser!
Keep experimenting and building amazing AR experiences!