AI red teaming & LLM evaluation

HarmBench: open-source red teaming benchmark

HarmBench is an open-source red teaming benchmark from Center for AI Safety. It is released under the MIT license and is offered as: CLI, Self-hosted.

  • Last reviewed

Best for

Researchers who need a reproducible way to compare red teaming attacks and refusal defenses across many models

Consider instead if

  • You want a ready-to-run scanner for one model or LLM endpoint rather than a research benchmark. See garak.

What HarmBench does

HarmBench is an evaluation framework for automated red teaming of language models. The README describes it as a framework for evaluating red teaming methods and LLM attacks and defenses, and it cites 18 red teaming methods and 33 target LLMs and defenses. You run a pipeline of scripts that generates test cases, generates completions from the target model, and has a classifier label each completion; the classifiers are published on Hugging Face. It supports models loaded through transformers, several closed-source APIs and some multimodal models. The code is MIT-licensed on GitHub, and the last push to the repository was on 2024-08-16. It is a research benchmark you run yourself, not a scanner for production applications.

This summary is our own wording of the sourced facts on this page.

Key facts

Each value links to the page that states it, with the date we checked it.

Latest release
Not documented in the sources we checked
API reference
Not documented in the sources we checked
Quickstart
Not documented in the sources we checked
Security page
Not documented in the sources we checked
Attestations or disclosure
Not documented in the sources we checked

Capabilities

As documented by the vendor or project. The tag is our label from a controlled vocabulary.

Integrations

Where HarmBench fits in our AI security layers

Our analysis

Our editorial model, not a standard. The primary layer follows the category, except for tools whose main documented job is detection and response; other layers rest on a capability the sources document. How the model works.

AI security layers that HarmBench covers, with the role, how each applies and what it rests on
LayerRoleHow it appliesBased on
L4 Testing Testing and red teaming Primary Attack and evaluate models, apps and agents on purpose, before release and after every change, to find what the other layers miss. Follows its category, AI red teaming & LLM evaluation

OWASP LLM Top 10 mapping

Our analysis

The risk list is OWASP's (Top 10 for LLM Applications, 2025). The mapping is our analysis, and each row rests on a capability the sources document.

No OWASP LLM risk is mapped to this tool in our analysis.

Alternatives and related tools

More in AI red teaming & LLM evaluation, ranked within the category by Coverage Score.

garak

NVIDIA

Open sourceApache-2.0
  • CLI
  • Library
  • Self-hosted

Probes language models and LLM apps for prompt injection, jailbreaks, data leakage and more.

Best for: Teams that want a free command-line scanner they can point at any model or LLM endpoint before release

Coverage Score 82 out of 100
  • LLM01 Prompt Injection
  • LLM02 Sensitive Information Disclosure
  • LLM09 Misinformation

Reviewed

Giskard

Giskard AI

Open sourceApache-2.0 Freemium
  • Library
  • Self-hosted
  • SaaS
  • On-prem

Generates adversarial test suites for LLM agents and RAG apps, runs them and reports failures by threat type.

Best for: Python teams that want a free library to scan an LLM agent or RAG app for prompt injection and harmful output, and to write pass or fail checks for it

Coverage Score 81 out of 100
  • LLM01 Prompt Injection
  • LLM02 Sensitive Information Disclosure
  • LLM09 Misinformation

Reviewed

Promptfoo

OpenAI (Promptfoo)

Open sourceMIT Freemium
  • CLI
  • Library
  • Self-hosted
  • SaaS
  • On-prem

Runs evals and red team scans against LLM apps from a CLI or CI pipeline and writes a vulnerability report.

Best for: Developer teams that want one open-source CLI for both prompt evals and red teaming, run locally and in CI

Coverage Score 80 out of 100
  • LLM01 Prompt Injection
  • LLM02 Sensitive Information Disclosure
  • LLM09 Misinformation

Reviewed

HarmBench FAQ

Is HarmBench open source?

Yes. HarmBench is released under the MIT license, and the code is on GitHub at centerforaisafety/HarmBench.

What does HarmBench measure?

It runs red teaming methods against target models and uses a classifier to label whether each completion shows the targeted behavior, so attack success rate can be computed.

How recently has HarmBench been updated?

The GitHub API shows the repository is not archived and was last pushed to on 2024-08-16.

Key facts you can cite

We have no commercial relationship with Center for AI Safety.

Sources & last reviewed

Last reviewed . We compile from the vendors' own public pages and repositories and we do not run the products. Source links open in a new tab. Found a mistake? Report a correction.