Inspiration

We were inspired by a friend’s Connect 4 web app where you could play against a bot. It showed us how a classic physical game can feel fresh and approachable when paired with a simple web experience. That pushed us to try something more hands on and more challenging: solving a real Rubik’s Cube using a camera

What it does

RubiksMagic lets you scan each face of a Rubik’s Cube with your webcam. The app detects the colors on every face, checks that everything is consistent, then solves the cube and guides you through the solution move by move so you can follow along in real life

How we built it

The frontend is built with React and walks the user through scanning all six faces in a clear and friendly flow. Each image is sent to a FastAPI backend that handles validation and processing.

For detection, we analyze the image and label the nine stickers on a face. A key rule is that the center sticker must match the face the user selected, since the center defines the face color. Once all faces are captured, we pass the full cube state into cube solver 1.1.4 to compute a valid solution. The result is returned as a readable sequence of moves like 𝑅,𝑈,𝑅′,𝑈′R,U,R′,U′

Challenges we faced

One of our biggest challenges was unclear system design between the frontend and backend expectations. Early on, the frontend assumed certain responses and states that the backend did not always guarantee, which led to mismatches in data flow and error handling. We had to step back, clearly define API contracts, and standardize response formats so both sides of the project spoke the same language What we learned

We learned how important clear validation and user feedback are in computer vision projects. A system is only useful if it helps users recover from mistakes. We also gained real experience designing clean APIs and connecting frontend and backend systems smoothly.

What’s next

We want to improve detection in tougher lighting, add visual guidance to help users align the cube during scanning, and support more Rubik’s Cube variants in the future. Our goal is to make RubiksMagic a fun and approachable way to learn how to solve a cube 🎉

Built With

Share this project:

Updates