AI Depth Map Generator
Upload any photo and generate a stunning depth map visualization using AI. See how far away each part of the scene is from the camera. Great for 3D effects, AR/VR, and creative photography. Runs 100% in your browser.
Drop a photo here or click to upload
Supports JPG, PNG, WebP
How AI Depth Estimation Works
This tool uses Depth Anything, a foundation model for monocular depth estimation developed by researchers at TikTok and the University of Hong Kong. It predicts how far each pixel in a photo is from the camera, creating a depth map from a single 2D image. The model processes visual cues like perspective, texture gradients, object sizes, and occlusion patterns to infer 3D structure.
The AI model runs entirely in your browser using Transformers.js. It is downloaded once (around 50 MB) and cached for offline use. No image data ever leaves your device.
Reading a Depth Map
- Red/warm colors — Objects close to the camera (foreground)
- Blue/cool colors — Objects far from the camera (background)
- Green/yellow — Mid-range distances
- Smooth gradients — Continuous surfaces like floors, walls
- Sharp edges — Distinct depth boundaries between objects
Creative and Practical Uses
Depth maps unlock a world of creative possibilities. Use them to create parallax 3D effects from flat photos, generate bokeh (background blur) in post-processing, or build AR experiences that interact with scene geometry. In 3D modeling, depth maps help create displacement maps for realistic terrain and surfaces.
Photographers use depth maps to understand scene composition and depth of field. Game developers use them for collision detection and scene reconstruction. Robotics engineers use depth estimation for navigation and obstacle avoidance. This tool lets you experiment with all these concepts for free.
Tips for Better Depth Maps
Photos with clear foreground and background separation produce the most dramatic depth maps. Outdoor landscapes, room interiors, and street scenes work exceptionally well. Avoid flat, textureless images (like a white wall) as there are fewer depth cues for the model to work with. Higher resolution images give more detailed depth maps.
Grayscale vs Colour Depth Map: Which One Do You Actually Need?
The two download buttons produce different files for different jobs, and picking the wrong one is the most common mistake with this tool. The colour map applies a viridis-style palette so you can read relative distance by eye — use it for presentations, composition review, and anything a human will look at. The grayscale map is the one software actually consumes: a single luminance channel where white is near and black is far. That is the format Photoshop’s Lens Blur depth channel, Blender’s displacement modifier, Unreal’s heightmap import, and most parallax and 2.5D generators expect. Feed a colour map into a displacement modifier and you get geometry driven by hue rather than distance, which is why terrain comes out banded and wrong. Note that monocular depth estimation returns relative depth, not metres: the model tells you what is nearer than what, not how far away anything is, so a grayscale map is fine for displacement and blur but not for measurement. Use Copy Image to paste the colour map straight into a document or chat, and Download Grayscale when the file is going into a 3D or compositing pipeline. Updated 2026-08-28.
Tips for Best Results
Start with the default settings to see how the tool works, then customize to match your needs. Preview your output before downloading or sharing to catch any adjustments. Use high-quality inputs where possible — better source material produces better results. Save your work frequently using the download or copy buttons. This tool runs entirely in your browser, so your creations are never uploaded to any server and remain completely private.
Frequently Asked Questions
Is my photo uploaded to any server?
No. The depth estimation model runs entirely in your browser. Your photos never leave your device. No data is sent anywhere.
What is a depth map?
A depth map is a visual representation of how far each part of an image is from the camera. Close objects appear in warm colors (red/yellow) and distant objects appear in cool colors (blue/green). It encodes 3D distance information from a 2D photo.
What can I use depth maps for?
Depth maps are used for creating 3D parallax effects, applying realistic bokeh blur, building AR/VR experiences, 3D printing terrain models, video game development, robotic navigation, and creative photography effects.
Does it work offline?
Yes. After the first use, the AI model is cached in your browser. You can generate depth maps completely offline without an internet connection.
What photo types work best?
Photos with clear foreground and background separation work best. Outdoor landscapes, room interiors, street scenes, and portraits all produce excellent depth maps. Flat textureless images give less interesting results.
What browsers are supported?
All modern browsers are supported: Chrome, Firefox, Safari, and Edge. The tool uses WebAssembly for cross-browser AI inference.
Should I download the grayscale or the colour depth map?
Download grayscale when the file is going into software: it is a single luminance channel where white is near and black is far, which is what Photoshop Lens Blur, Blender displacement, Unreal heightmap import and most parallax generators expect. Use the colour map when a person is going to look at it, since the palette makes relative distance readable at a glance. Feeding a colour map into a displacement modifier drives geometry by hue instead of distance and produces banded, wrong terrain.
Can I copy the depth map without downloading a file?
Yes. Click Copy Image and the colour depth map goes straight to your clipboard, ready to paste into a document, slide, or chat. If your browser blocks clipboard image writes — Firefox is the usual case — the tool tells you and you can use the download buttons instead.
Does the depth map give real distances in metres?
No. Depth Anything performs relative monocular depth estimation, so it tells you what is nearer than what, not how far anything actually is. That is enough for parallax, bokeh, displacement and compositing, but not for measurement. Real metric depth needs a stereo pair, a LiDAR or time-of-flight sensor, or a model calibrated against known camera intrinsics.