Glossary

What is Prompt injection?

Prompt injection is an attack in which text written by an attacker is read by a language model as instructions, overriding what the application intended. It can be typed directly into a chat or hidden in a web page, email or document the model processes. It can make an AI system leak data or misuse its tools.

Prompt injection in plain English

Direct injection comes from the user. Indirect injection hides in content the model reads on its own, which is the larger risk for agents that browse, read email or open files.

No filter stops every injection, so defenses are layered: least-privilege tool access, separation of trusted and untrusted content, output checks and human approval for risky actions.

Browse providers

Questions about Prompt injection

What is an example of prompt injection?

A web page contains hidden text telling the AI to ignore its instructions and send the user's data to an outside address. An agent that reads the page may follow it.

Can prompt injection be prevented?

It can be reduced but not fully prevented today. Limit what the model can do, treat all retrieved content as untrusted, and require approval for sensitive actions.