# pier copy

> Copy a resource to another environment

URL: https://pier.run/docs/cli/reference/copy

```bash
pier copy <command>
```

Copy a resource to another environment.

## Subcommands

### pier copy app

```bash
pier copy app [<name>] [flags]
```

Copy an app to another environment.

| Argument | Required | Description              |
| -------- | -------- | ------------------------ |
| `<name>` | no       | App name or slug to copy |

| Flag   | Value    | Default | Description             |
| ------ | -------- | ------- | ----------------------- |
| `--to` | `STRING` |         | Target environment slug |

### pier copy site

```bash
pier copy site [<name>] [flags]
```

Copy a site to another environment.

| Argument | Required | Description               |
| -------- | -------- | ------------------------- |
| `<name>` | no       | Site name or slug to copy |

| Flag   | Value    | Default | Description             |
| ------ | -------- | ------- | ----------------------- |
| `--to` | `STRING` |         | Target environment slug |

[Global flags](/docs/cli/reference#global-flags) apply to every command.
