# What is Prompt-injection defense? Definition and meaning

Techniques that stop text in web pages, files or tool results from hijacking the agent.

## Definition

**Prompt-injection defense**: Techniques that stop text in web pages, files or tool results from hijacking the agent.

In short: Protecting agents from hostile instructions in data.

## When it is used

Safe use of agents on untrusted content.

## Where it fits

Prompt-injection defense belongs to **Operations** in the [Agentic AI](/topics/agentic-ai) topic. These are the other terms in the same group:

- **[Tracing](/glossary/tracing)**: Captures prompts, tool calls, inputs and outputs of every step as a trace.
- **[Evals](/glossary/evals)**: Test sets and graders that measure quality of a prompt, model or agent.
- **[Regression boards](/glossary/regression-boards)**: A standing set of benchmark rows that is re-run in full after each change so that a new fix cannot silently break an old result.
- **[Cost and latency budgets](/glossary/cost-and-latency-budgets)**: Explicit ceilings on tokens, tool calls and seconds for an agent run.
- **[Sandboxing](/glossary/sandboxing)**: Executes code and tools inside a restricted container or virtual machine.

## Learn more

The full guide to **[Prompt-injection defense](/tools/prompt-injection-defense)** explains how it works, when to use it and how it compares with the alternatives, with examples. The [glossary](/glossary) lists every term on the site from A to Z.

Previous term: [Prompt tuning](/glossary/prompt-tuning) · Next term: [PromptFoo](/glossary/promptfoo)
