--- title: "cp" slug: "cp" updated: 2026-10-08T04:57:36Z published: 2026-10-08T04:57:36Z canonical: "cli.ncloud-docs.com/cp" --- > ## Documentation Index > Fetch the complete documentation index at: https://cli.ncloud-docs.com/llms.txt > Use this file to discover all available pages before exploring further. # cp Available in Classic and VPC Upload an object to a bucket, or download an object that has already been uploaded to local or copy it to another location. ## Syntax The `cp` syntax is as follows: ``` aws s3 cp \ \ \ [--dryrun] \ [--quiet] \ [--include ] \ [--exclude ] \ [--recursive] \ [--follow-symlinks | --no-follow-symlinks] \ [--no-guess-mime-type] \ [--storage-class ] \ [--content-type ] \ [--cache-control ] \ [--content-disposition ] \ [--content-encoding ] \ [--content-language ] \ [--only-show-errors] \ [--no-progress] \ [--page-size ] \ [--ignore-glacier-warnings] \ [--metadata ] \ [--copy-props ] \ [--metadata-directive ] \ --endpoint-url ``` ## Options This section describes the options available when running `cp`. ### Required options The following options are required for `cp`. | Options | Type | Required | Description | | --- | --- | --- | --- | | `<source>` | String | Required | Source path - Local path or S3 URI in the format of `s3://{bucket_name}[/{object_name}]` | | `<destination>` | String | Required | Destination path - Local path or S3 URI in the format of `s3://{bucket_name}[/{object_name}]` | ### Optional options These are the optional options for `cp`. Options that are not specified will use their default values. | Options | Type | Required | Description | | --- | --- | --- | --- | | `--dryrun` | Boolean | Optional | Checks the results of the command without actually executing it. | | `--quiet` | Boolean | Optional | Does not display the response. | | `--include` | String | Optional | Includes only objects matching the specified pattern in the command. - Applied in the specified order. | | `--exclude` | String | Optional | Excludes objects matching the specified pattern from the command. - Applied in the specified order. | | `--recursive` | Boolean | Optional | Copies items in subdirectories of the specified path. | | `--follow-symlinks`, `--no-follow-symlinks` | Boolean | Optional | Whether to upload the content of files pointed to by symbolic links - Default: `--follow-symlinks` - Applies only when uploading objects from the local file system. | | `--no-guess-mime-type` | Boolean | Optional | Disables automatic guessing of the content type for objects to be uploaded. | | `--storage-class` | String | Optional | Specifies the storage class for the object. - `STANDARD` (default) \| `ONEZONE_IA` \| `DEEP_ARCHIVE` | | `--content-type` | String | Optional | Define explicit content type. | | `--cache-control` | String | Optional | Set caching behavior. | | `--content-disposition` | String | Optional | Specifies how to display objects. | | `--content-encoding` | String | Optional | Set content encoding. | | `--content-language` | String | Optional | Set content language. | | `--only-show-errors` | Boolean | Optional | Displays only errors; other response values are not displayed. | | `--no-progress` | Boolean | Optional | Does not display file transfer progress - Not applied if `--quiet` or `--only-show-errors` is specified | | `--page-size` | Integer | Optional | Number of items per page - `1`-`1000` | | `--ignore-glacier-warnings` | Boolean | Optional | Does not display warnings regarding unsupported operations (such as copying, downloading, or moving) on objects in the Deep Archive. | | `--metadata` | String | Optional | Set up metadata to store with the object. | | `--copy-props` | String | Optional | Sets the attribute values to copy from the source object. - `none` \| `metadata-directive` \| `default` (default) - `none`: Does not copy attributes. - `metadata-directive`: Copies content-related attributes and metadata. - `default`: Copies and adds tags to attributes targeted by `metadata-directive`. - Applies only when copying from Ncloud Storage to Ncloud Storage. | | `--metadata-directive` | String | Optional | Metadata handling options when copying - `COPY` (default) \| `REPLACE` - `COPY`: Copies original. - `REPLACE`: Redefines. | ### Common options For information about the options common to all `aws` subcommands, see [Ncloud Storage options](/docs/en/storage-ncloudstorage#%EC%98%B5%EC%85%98). ## Examples If the request is successful, the source path and destination path are displayed along with the type of job performed. ### Command The following is an example command for uploading a local file to a bucket. ``` aws s3 cp sample.txt s3://my-test-bucket/docs/sample.txt \ --endpoint-url=https://kr.ncloudstorage.com ``` The following is an example command for copying an object to a different location within the bucket. ``` aws s3 cp s3://my-test-bucket/img/image.png s3://my-test-bucket/img/copy.png \ --endpoint-url=https://kr.ncloudstorage.com ``` The following is an example command for changing an object's storage class. ``` aws s3 cp s3://my-test-bucket/img/copy.png s3://my-test-bucket/img/copy.png \ --storage-class DEEP_ARCHIVE \ --endpoint-url=https://kr.ncloudstorage.com ``` The following is an example command for downloading an object from a bucket to your local machine. ``` aws s3 cp s3://my-test-bucket/docs/sample.txt ./ \ --endpoint-url=https://kr.ncloudstorage.com ``` ### Output The following is an example output for uploading a local file to a bucket. ``` upload: ./sample.txt to s3://my-test-bucket/docs/sample.txt ``` The following is an example output for copying an object to a different location within a bucket. ``` copy: s3://my-test-bucket/img/image.png to s3://my-test-bucket/img/copy.png ``` The following is an example output for changing an object’s storage class. ``` copy: s3://my-test-bucket/img/copy.png to s3://my-test-bucket/img/copy.png ``` The following is an example output for downloading an object from a bucket to your local machine. ``` download: s3://my-test-bucket/docs/sample.txt to ./sample.txt ```