> ## Documentation Index
> Fetch the complete documentation index at: https://docs.poly.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# poly revert

> Reference for the `poly revert` command.

Revert local changes back to the last known remote state.

Examples:

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
poly revert
poly revert file1.yaml file2.yaml
```

With no arguments, reverts every local change in the working tree; pass file paths to revert only those files.

| Argument | Description |
| - | - |
| `files` | List of files to revert. If not specified, reverts all changes. |

> [!WARNING]
>
> **Reverting cannot be undone**
>
> Reverting discards local edits with no way to recover them — run [`poly diff`](https://docs.poly.ai/adk/reference/cli/diff) or [`poly status`](https://docs.poly.ai/adk/reference/cli/status) first if you're unsure what will be lost.

`--json` output shape:

```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
{
  "success": true,
  "files_reverted": []
}
```
