Table Of Contents


User Guide

First time using the AWS CLI? See the User Guide for help getting started.

[ aws . s3api ]



Returns the replication configuration of a bucket.

See also: AWS API Documentation

See 'aws help' for descriptions of global parameters.


--bucket <value>
[--cli-input-json <value>]
[--generate-cli-skeleton <value>]


--bucket (string)

--cli-input-json (string) Performs service operation based on the JSON string provided. The JSON string follows the format provided by --generate-cli-skeleton. If other arguments are provided on the command line, the CLI values will override the JSON-provided values. It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally.

--generate-cli-skeleton (string) Prints a JSON skeleton to standard output without sending an API request. If provided with no value or the value input, prints a sample input JSON that can be used as an argument for --cli-input-json. If provided with the value output, it validates the command inputs and returns a sample output JSON for that command.

See 'aws help' for descriptions of global parameters.


The following command retrieves the replication configuration for a bucket named my-bucket:

aws s3api get-bucket-replication --bucket my-bucket


    "ReplicationConfiguration": {
        "Rules": [
                "Status": "Enabled",
                "Prefix": "",
                "Destination": {
                    "Bucket": "arn:aws:s3:::my-bucket-backup",
                    "StorageClass": "STANDARD"
                "ID": "ZmUwNzE4ZmQ4tMjVhOS00MTlkLOGI4NDkzZTIWJjNTUtYTA1"
        "Role": "arn:aws:iam::123456789012:role/s3-replication-role"


ReplicationConfiguration -> (structure)

Container for replication rules. You can add as many as 1,000 rules. Total replication configuration size can be up to 2 MB.

Role -> (string)

Amazon Resource Name (ARN) of an IAM role for Amazon S3 to assume when replicating the objects.

Rules -> (list)

Container for information about a particular replication rule. Replication configuration must have at least one rule and can contain up to 1,000 rules.


Container for information about a particular replication rule.

ID -> (string)

Unique identifier for the rule. The value cannot be longer than 255 characters.

Prefix -> (string)

Object keyname prefix identifying one or more objects to which the rule applies. Maximum prefix length can be up to 1,024 characters. Overlapping prefixes are not supported.

Status -> (string)

The rule is ignored if status is not Enabled.

SourceSelectionCriteria -> (structure)

Container for filters that define which source objects should be replicated.

SseKmsEncryptedObjects -> (structure)

Container for filter information of selection of KMS Encrypted S3 objects.

Status -> (string)

The replication for KMS encrypted S3 objects is disabled if status is not Enabled.

Destination -> (structure)

Container for replication destination information.

Bucket -> (string)

Amazon resource name (ARN) of the bucket where you want Amazon S3 to store replicas of the object identified by the rule.

Account -> (string)

Account ID of the destination bucket. Currently this is only being verified if Access Control Translation is enabled

StorageClass -> (string)

The class of storage used to store the object.

AccessControlTranslation -> (structure)

Container for information regarding the access control for replicas.

Owner -> (string)

The override value for the owner of the replica object.

EncryptionConfiguration -> (structure)

Container for information regarding encryption based configuration for replicas.

ReplicaKmsKeyID -> (string)

The id of the KMS key used to encrypt the replica object.