sincecutoff.com
← all changes

aws s3 copy operations add all option to --copy-props

Introduced 2026-06-16 · score 0.96

HOW TO USE IT

For S3-to-S3 copies with `cp`, `mv`, or `sync`, set `--copy-props all` to copy annotations, tags, and the metadata properties covered by `default`.

aws s3 cp s3://<source-bucket>/<source-key> s3://<destination-bucket>/<destination-key> --copy-props all
aws s3 mv s3://<source-bucket>/<source-key> s3://<destination-bucket>/<destination-key> --copy-props all
aws s3 sync s3://<source-bucket>/<source-prefix>/ s3://<destination-bucket>/<destination-prefix>/ --copy-props all

WHY THIS HELPS

When copying S3 objects with the AWS CLI, preserve their annotations, metadata, and tags.

REQUIREMENTS AND LIMITATIONS

  • Version: 2.35.6
  • --copy-props all: `--copy-props` applies only to S3-to-S3 copies. `all` copies annotations plus tags and properties covered by `default` (content type, content language, content encoding, content disposition, cache control, expires, and metadata). Set it for the requested preservation.
  • --metadata-directive: If set, disables `--copy-props`; do not set it when relying on `--copy-props all`.
  • Prerequisite: AWS CLI must be installed and configured to use the documented examples.
  • Prerequisite: For multipart copies, `all` may make additional `HeadObject`, `GetObjectTagging`, `PutObjectTagging`, `ListObjectAnnotations`, `GetObjectAnnotation`, and `PutObjectAnnotation` API calls.
  • The `all` option applies to S3 to S3 copy operations.

FIRST-PARTY EVIDENCE

Check the installed version and the source before using it. Entry JSON

Report a problem with this card