Adversarial example
An adversarial example is an input deliberately altered, often by changes too small for a person to notice, so that a machine learning model gets it wrong, frequently with high confidence.
A trained model draws boundaries in the space of possible inputs: one side is a cat, the other a dog. An attacker who can see the model's internals, or simply query it many times, can search for the smallest change that pushes an input across a boundary. In an image the change is spread thinly over many pixels, so a person sees the same picture while the model sees something else entirely and may report high confidence in its wrong answer.
The idea is older than deep learning. NIST's adversarial machine learning taxonomy dates early evasion attacks to 1988, and to 2004 work showing that linear classifiers used in spam filters could be fooled. It became a central topic in December 2013, when Christian Szegedy and colleagues reported that tiny, nearly imperceptible perturbations could make image classifiers fail, and that the same perturbations often fooled other networks trained on different data. A year later Ian Goodfellow, Jonathon Shlens and Szegedy argued that the cause was the largely linear behaviour of these models rather than overfitting, and introduced a fast way to generate such inputs, now known as the fast gradient sign method.
Attacks also work in the physical world. In 2017 researchers placed black and white stickers on a real stop sign and caused a road sign classifier to misread it in every lab image and in 84.8% of video frames captured from a moving car. Another team 3D-printed a toy turtle that Google's image classifier labelled a rifle from almost any angle. Such results need context: one Google Brain researcher pointed out that removing a stop sign altogether is a far easier way to confuse a self-driving car.
NIST's March 2025 taxonomy files adversarial examples under evasion attacks, which change inputs at the time a model is used, as opposed to poisoning attacks, which tamper with training data. Jailbreaks and prompt injection against language models are close relatives: inputs crafted to make a model do what its developers did not intend.
The most common defence is adversarial training, which adds attacked examples to the training data so the model learns to resist them. It helps but does not end the problem, because an attacker who knows the defence can search for new perturbations. In practice the concern is greatest where models make safety or security decisions from sensor data, such as vehicle perception, medical imaging and content filters.
It is an input, such as an image, audio clip or piece of text, that has been changed on purpose so that an AI model misreads it. The change is often too small for people to notice. A classic case is an image that looks unchanged to a person but is confidently classified as something else. Models rely on statistical patterns that do not match how people see. Goodfellow and colleagues argued in 2014 that the largely linear behaviour of neural networks lets many tiny changes add up to a large effect on the output. The same explanation accounts for why an adversarial example built for one model often fools others. Researchers have shown that stickers on a stop sign can make a road sign classifier misread it, including from a moving vehicle. Real vehicles combine several sensors and checks, so a lab result does not mean a car on the road would crash. The research does show why perception systems need testing against deliberate manipulation. The main method is adversarial training: generating attacked inputs during training so the model learns to handle them. Other measures include checking inputs, combining several models and limiting how often an attacker can query a system. None of these is complete, so defences are usually tested against attacks designed with knowledge of them.Common questions
What is an adversarial example in simple terms?
Why do neural networks fall for adversarial examples?
Can adversarial examples fool self-driving cars?
How do you defend against adversarial examples?
Search for "adversarial examples", "evasion attack" or "adversarial machine learning" to find the research. NIST's adversarial machine learning taxonomy is a reliable map of attack types and terms, and the original papers are on arXiv. Be cautious with demonstrations that claim to fool deployed systems: check whether they worked against the real product or a model in a lab.Finding more
Working out what this means for your business?
Aileron Shift builds the systems behind this site: AI newsrooms that research, write and publish on their own, marketing automation and WordPress hosting for companies that need to move faster than their competitors.