About Rubik Mosaic Generator
Rubik Mosaic Generator is a free browser-based tool that turns any photograph into a mosaic built from real 3×3 Rubik's Cubes. Upload an image, choose how many cubes wide the mosaic should be, and the app quantises every pixel to the six standard cube-sticker colours (white, yellow, red, orange, blue, green), with optional Floyd–Steinberg dithering to suggest in-between shades.
What it does
- Converts photos into cube-accurate mosaic patterns.
- Generates a printable, cube-by-cube build sheet with sticker layouts.
- Renders a side-by-side original vs. mosaic viewer so you can compare fidelity.
- Exports a PDF you can carry to your build table.
Who it's for
Cubers who want to build wall-sized cube art, teachers running maths-and-art classroom projects, and hobbyists trying to see how far six colours can go. Everything runs locally in your browser — your images never leave your device.
Who built it
The generator, the guides on this site and the sister Cube Solver are built and maintained by Mohammed Al Riyaz D, a software engineer based in Chennai, India, with more than eight years of experience in backend systems, cloud services and applied AI. He writes the guides from the generator's actual behaviour.
Trend2Print is the name the project is published under; it is a one-person project, not a company. Every guide shows when it was first published and when it was last updated, and corrections are welcome: if something on the site doesn't match what the generator actually does, email mail.to.alriyaz@gmail.com and it will be fixed.
How the guides are written
The guides describe how the generator behaves in practice: the colour matching, dithering, depth-limited move search and export formats documented here are the ones in the shipped tool. Where a guide gives a cube count, size or budget, it is calculated from stated assumptions (for example, a nominal 56 mm cube) rather than presented as a measurement of a specific build. The worked examples are generated planning grids, and are labelled that way on every page.
How it works under the hood
When you upload an image, the tool first resizes it to the target mosaic resolution with browser canvas smoothing and a four-times oversampled box average. It compares each averaged pixel with the six cube colours in linear RGB, weighting the channels and, in High fidelity mode, luminance so shadows and highlights stay in the right tonal range. An optional Floyd–Steinberg pass spreads the rounding error into surrounding pixels, which is what lets the six-colour palette appear to show shades of pink, brown, teal, and grey when you step back from the wall.
The second half of the tool is the solver. Each 3×3 tile in the mosaic becomes a target "face pattern" that a real Rubik's Cube has to be manipulated into showing. Because we only care about one face — not the whole cube — the solver runs a short depth-limited search using standard face turns (U, D, L, R, F, B). It searches sequences up to five moves and returns the closest front-face match it finds. Complex targets may remain a partial match, and a face centre cannot change through legal turns. Search runs lazily, one page of cubes at a time, so the interface stays responsive.
Why it exists
Cube mosaics have been a niche art form since the late 2000s, but every existing generator we could find either required desktop software, uploaded your images to a server, or hid the move sequences behind a paywall. I wanted something that was free, ran entirely in the browser, produced a printable build sheet you can bring to a maker space, and treated the process with the same seriousness that dedicated cubers already bring to their speed-solving.
What it isn't
This project is not affiliated with, endorsed by, or sponsored by Rubik's Brand Ltd or any cube manufacturer. "Rubik's Cube" is a trademark of its respective owner. The generator is an independent hobby project. If you're looking to buy the specific cubes used in real-world mosaic builds, please support the manufacturer of your choice directly.
Credits
The dithering implementation follows Floyd and Steinberg's 1976 error-diffusion method. The cube-state model uses standard face-turn notation documented by the speedcubing community. Implementation details are described here so they can be checked against the generator's actual output rather than treated as claims of laboratory-grade colour accuracy.