Variational Autoencoder (VAE)

Last Updated: July 29, 2026 | By Mihail Sebastian | AI Dictionary

A generative model that encodes data as probability distributions in a latent space, so sampling from that space decodes into new, realistic data points.

What is a Variational Autoencoder (VAE)?

A variational autoencoder (VAE) is a generative model that encodes data as probability distributions in a compressed latent space, then decodes samples from that space into new data resembling its training set.

It takes the compress-and-reconstruct design of the autoencoder and rebuilds it for generation. Where an ordinary autoencoder answers “what does this data look like compressed?”, a VAE answers “what else could this data have looked like?”

How a VAE Works

The encoder does not map an input to a single code. It outputs a mean and a variance, defining a small probability distribution for that input, and the decoder draws a point from the distribution to reconstruct the data.

Training balances two pressures. The reconstruction term demands accurate rebuilds, while a second term pushes every distribution toward a shared standard shape, so the latent space stays smooth and connected. Smoothness is what makes generation work: any sampled point decodes into something plausible.

Variational Autoencoder vs Autoencoder

The practical difference: a VAE generates data, an autoencoder compresses it. A standard autoencoder maps each input to one fixed point in latent space, which serves reconstruction well but leaves the space between points meaningless; sampling there produces junk. A VAE’s distributions fill the space smoothly, so any sample decodes into coherent new data.

CriterionVariational AutoencoderAutoencoder
Latent codeA probability distribution per inputOne fixed point per input
Main useGenerating new dataCompression, denoising, anomaly detection
Same input twiceOutput varies with each sampleIdentical output
Training objectiveReconstruction error plus a term that keeps the latent space smoothReconstruction error only

Example of a VAE

Train a VAE on a large dataset of face photographs. The encoder learns to place each face in latent space along directions that loosely track pose, lighting, and facial features. Sample a random point and the decoder returns a face that belongs to no one.

Encode two real people and walk the line between their codes: the decoder produces a gradual morph from one face into the other. Compared with a GAN, a VAE’s images run blurrier but its training is far more stable, the standing trade-off between the two generative designs.

Related AI terms: Autoencoder · Generative Adversarial Network · Generative AI · Latent Space

Did you like the Variational Autoencoder (VAE) gist?

Learn about 250+ need-to-know artificial intelligence terms in the AI Dictionary.

Mihail Sebastian — Writes about AI governance, regulation, and the technology behind them. Placeholder bio — replace with a real credential line. About

Read the Governor's Letter

Stay ahead with Governor's Letter, the newsletter delivering expert insights, AI updates, and curated knowledge directly to your inbox.

By subscribing to the Governor's Letter, you consent to receive emails from AI Guv.
We respect your privacy - read our Privacy Policy to learn how we protect your information.

Browse All AI Terms A–Z

Every term in the dictionary, in alphabetical order. Jump to a letter or scroll the full list.

A

B

C

D

E

F

G

H

I

J

K

L

M

N

O

P

Q

R

S

T

U

V

W

X

Y

Z