---
title: "Rerun only failed tests"
description: "Rerun only the tests that failed when you rerun a workflow from failed. This free, built-in Smarter Testing capability needs no extra configuration."
platform: "Cloud"
doc_version: "unversioned"
last_updated: "2026-10-13"
cloud_plans: "Free, Performance, Scale"
version_control: "All supported providers"
---

> For current CircleCI product defaults, deprecated patterns, and Cloud/Server differences, see [AGENTS.md](https://circleci.com/docs/AGENTS.md).
>
> For the complete documentation index and site structure, see [llms.txt](https://circleci.com/docs/llms.txt).

# Rerun only failed tests

**Cloud plans:** Free, Performance, Scale

**Version control:** [All supported providers](https://circleci.com/docs/guides/integration/version-control-system-integration-overview/)

Rerunning only failed tests is built in to `circleci testsuite run` and is free, with no extra configuration. When you rerun a workflow from failed, `circleci testsuite run` reruns only the tests that failed in the previous run, instead of your entire test suite. This shortens time-to-feedback and avoids spending credits on tests that already passed.

## Prerequisites

Before rerunning only failed tests, ensure you have completed the [Getting Started With Smarter Testing](https://circleci.com/docs/guides/test/getting-started-with-smarter-testing/) guide and have:

*   Configured your `.circleci/test-suites.yml` with `discover` and `run` commands.
    
*   Replaced your test command with `circleci testsuite run`.
    

## Rerun a workflow from failed

You can rerun a workflow from failed in any of the following ways:

*   **Web app**: Select **Rerun workflow from failed**. See [Rerunning a Workflow’s Failed Jobs](https://circleci.com/docs/guides/orchestrate/workflows/#rerunning-a-workflows-failed-jobs).
    
*   **API**: Use the [rerun workflow endpoint](https://circleci.com/docs/api/v3#tag/workflows/POST/api/v3/workflows/{id}/rerun.body.is_from_failed) with `is_from_failed` set to `true`.
    
*   **CLI**: Run `circleci workflow rerun <workflow-id> --from-failed`.
    

## Rerun failed tests automatically

To rerun failed tests automatically during the same run, without rerunning the workflow, use [Auto Rerun Failed Tests](https://circleci.com/docs/guides/test/auto-rerun-failed-tests/), which has a credit charge above your plan’s allowance.

This page covers `circleci testsuite`. If you use the legacy `circleci tests run` command, see [Rerun Failed Tests With the Tests Run Command](https://circleci.com/docs/guides/test/rerun-failed-tests/).

## Next steps

*   [Use Static Test Splitting](https://circleci.com/docs/guides/test/use-static-test-splitting/) to split your tests across parallel nodes.
    
*   [Auto Rerun Failed Tests](https://circleci.com/docs/guides/test/auto-rerun-failed-tests/) to automatically retry flaky tests.