Private image x (hidden from server) Attacker reconstruction x̂ (evolving)
⚠ Couldn't load the 3D engineThree.js failed to load from the CDN. Check your connection and reload.

Gradient Leakage Attack on Federated Learning

Federated learning promises that a client's raw data never leaves its device — only model gradients are shared. This simulator shows why that promise is weaker than it sounds: it implements a real, minimal version of the Deep Leakage from Gradients attack, where an adversary who intercepts a single leaked gradient runs its own gradient descent to reconstruct the private 8×8 image that produced it, watching a random noise grid converge pixel-by-pixel onto the hidden original. Sliders let you dial in the differential-privacy defenses real federated systems use — Gaussian noise injection and gradient clipping — and watch the reconstruction stall as the defenses strengthen, with live readouts tracking the gradient-matching loss, reconstruction error, and the leaked gradient's norm.