Image Tools
Photomosaic Generator - Pixel Art Mosaic Effect
Upload a photo and transform it into a color-block mosaic with square or circular tiles. Adjust grid size and gap, then download the result as a PNG.
Upload an image to get started
What is a photo mosaic?
A photo mosaic is an image made up of many small tile images arranged so that when viewed as a whole, they form a larger target image. Each tile’s average color is matched to the corresponding region of the target image. The closer you stand (or the smaller the tiles), the more the tile images dominate; further away, the more the original image is visible.
How it works
- The target image is divided into a grid of equally-sized cells.
- The average color of each cell is calculated.
- Each cell is replaced by the tile whose average color is the closest match (using Euclidean distance in RGB color space).
- The result is assembled into the final mosaic.
Tips for best results
- More tile images = better color matching: a library of 100+ diverse images produces much better color coverage than 10–20.
- High-contrast target images: images with strong contrast and clear subjects work better than flat, low-contrast ones.
- Tile size tradeoff: smaller tiles create a more convincing mosaic when viewed close-up; larger tiles make individual tile images more recognizable.
History of photo mosaics
The modern photo mosaic was invented by Robert Silvers, who created the first computer-generated photo mosaic in 1993 as part of his MIT Media Lab work. He commercialized the technology and trademarked the term "Photomosaic." Early famous examples included a large portrait of Marilyn Monroe composed entirely of smaller portrait photos.
The technique is related to pointillism in painting (Georges Seurat, 1880s), where images are built from small dots of pure color that blend optically at a distance, and to halftone printing, which uses dots of varying size to simulate continuous tones.
Nearest-color matching explained
For each cell in the target image grid, the algorithm computes the cell's average color (R, G, B). It then searches the tile library for the tile whose own average color has the minimum Euclidean distance in RGB space:
distance = √((ΔR)² + (ΔG)² + (ΔB)²) More advanced implementations use Lab color space (perceptually uniform), which gives better visual results because equal distances in Lab space correspond more closely to equal perceptual differences than RGB distances do. Tiles can also be weighted to avoid repetition - reducing the "same tile everywhere" artifact when the library is small.