Connecting Amazon S3
This guide connects an Amazon S3 bucket to Hera Backup so your backups upload to your own AWS storage. You create a private bucket, a dedicated IAM user with least-privilege access, and an access key, then enter those details in Hera Backup.
AWS console wording is current as of 2026. AWS now recommends short-term credentials (IAM Identity Center) for human sign-in, but a dedicated IAM user with a long-lived access key is still the supported way for a server application like a WordPress plugin to reach S3.
Before you start
- Amazon S3 is part of the free Hera Backup plugin. Hera Backup Pro is not required.
- An AWS account with permission to create S3 buckets and IAM users.
- Decide on an AWS region close to your web server for faster uploads. The plugin's Region list offers these regions, so create the bucket in one of them:
us-east-1,us-east-2,us-west-1,us-west-2,af-south-1,ap-east-1,ap-south-1,ap-northeast-1,ap-northeast-2,ap-northeast-3,ap-southeast-1,ap-southeast-2,ca-central-1,eu-central-1,eu-west-1,eu-west-2,eu-west-3,eu-north-1,eu-south-1,me-south-1,sa-east-1.
Step 1: Create a private S3 bucket
- Sign in to the AWS Management Console and open S3.
- Click Create bucket.
- Enter a globally unique Bucket name (for example,
my-site-backups-hera).
Use a name without dots. Hera Backup reaches the bucket over HTTPS athttps://<bucket>.s3.<region>.amazonaws.com, and a name with dots fails the certificate check there. - Choose an AWS Region from the list above (note its code, for example
us-east-1). - Leave Block all public access enabled: your backups must stay private.
- Click Create bucket.
Step 2: Create a dedicated IAM user
Never use your AWS root or personal admin keys. Create a user just for backups.
- In the AWS console, open IAM > Users.
- Click Create user.
- Enter a User name (for example,
hera-backup-s3). - Do not enable console access (this user is for the API only). Click Next.
- On the permissions step, choose Attach policies directly: you will add a custom policy in the next step. Click Next, then Create user.
Step 3: Attach a least-privilege policy
Grant access only to your backup bucket.
- Open the user you just created, go to the Permissions tab, and choose Add permissions > Create inline policy.
- Switch to the JSON editor and paste (replace
my-site-backups-herawith your bucket name):
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:PutObject",
"s3:GetObject",
"s3:DeleteObject",
"s3:ListBucket",
"s3:AbortMultipartUpload"
],
"Resource": [
"arn:aws:s3:::my-site-backups-hera",
"arn:aws:s3:::my-site-backups-hera/*"
]
}
]
}
- Click Next, give the policy a name (for example,
HeraBackupS3Access), and click Create policy.
What each action is for:
s3:PutObject: uploading a backup, including each part of a large upload.s3:GetObject: downloading a backup to restore it, and checking that a backup file exists.s3:DeleteObject: deleting old backups when retention removes them.s3:ListBucket: the Test connection check and listing the backups in the bucket.s3:AbortMultipartUpload: cleaning up a large upload that failed or was cut off, so its uploaded parts do not stay in the bucket and keep costing storage.
The bucket ARN (without /) is required for s3:ListBucket; the object ARN (with /) is required for the object actions. Both lines are needed.
Step 4: Create an access key
- On the user's page, open the Security credentials tab.
- Under Access keys, click Create access key.
- For the use case, choose Application running outside AWS, then click Next and Create access key.
- Copy the Access key ID and the Secret access key now. The secret is shown only once.
_Note: redact both the Access key ID and Secret access key before publishing: treat them like a password._
Step 5: Configure in Hera Backup
- In WordPress, go to Hera Backup > Storages.
- Find the Amazon S3 card and click Connect (it reads Configure once the destination is connected).
- Enter:
Access key: the Access key ID from Step 4.
Secret key: the Secret access key from Step 4.
Bucket: the bucket name from Step 1.
Region: select the region you chose in Step 1. - Set Max backups to keep (0 = unlimited) if you want the plugin to delete older backups from this bucket. It is counted per schedule: when a scheduled backup finishes, that schedule's older backups here beyond this number are deleted. Manual and imported backups, the recovery point and the backup last restored are never deleted automatically. See Storage Retention and Cleanup.
- Click Test connection. Hera Backup checks that the bucket exists and is reachable with the credentials in the form (a
HeadBucketrequest, which uses thes3:ListBucketpermission from Step 3). No object is written during the test. A passing test shows Connection OK. - When the test passes, click Save.
What to expect
- Amazon S3 becomes a destination you can select for manual backups and schedules.
- Hera Backup builds each backup archive on your server first, then uploads it to the bucket. Each backup is one
.herafile at the top level of the bucket. - Archives larger than 100 MiB upload in parts of 64 MiB (a multipart upload). If a large upload fails, Hera Backup aborts it so its parts are removed from the bucket.
- If an upload fails, the backup is marked failed with the reason, and the finished archive is kept in the plugin's local backup folder when it can be.
- Storage, requests and data transfer are billed by AWS to your AWS account.
- Let Hera Backup manage retention (Max backups to keep (0 = unlimited)) rather than S3 lifecycle rules, so the plugin's backup list stays in sync with the bucket.
Troubleshooting
The Test connection check shows these messages:
| Message | Likely cause | Fix |
|---|---|---|
| Access key and secret key are required. | A key field is empty | Enter both the Access key and the Secret key |
| Bucket name is required. | The Bucket field is empty | Enter the bucket name from Step 1 |
| Access denied. The access key or secret was rejected, or the key has no permission on this bucket. | Wrong or rotated key, or the policy is missing s3:ListBucket or the bucket ARN |
Recheck both key values, or create a fresh access key; confirm the policy has all five actions and both ARNs |
| The bucket is in region ... but this connection is configured for ... | The selected Region does not match the bucket | Select the region the message names |
| Bucket "..." does not exist at this endpoint. | Wrong bucket name | Recheck the bucket name |
| Could not reach ... Check the endpoint and that outbound HTTPS is allowed. | Your host blocks outbound HTTPS | Ask your host to allow outbound HTTPS to AWS |