Site Builder Documentation
A step-by-step walk-through of making your own storage on Amazon's website, so the pictures and videos on your site are kept in a place you own, under your own account.
This is yours, not ours. You make the storage on your own Amazon account, in your own name, and you tell this site builder how to reach it. Your files sit in your storage, you can see them any time, and if you ever leave they stay with you.
It is the same arrangement as taking card payments here: that uses your own Stripe account, and this uses your own Amazon one.
You need this before you can upload a picture. This service keeps none of your files, so until your storage is set up, uploading a picture or a logo in the builder is refused. Typing in the address of a picture you keep somewhere else works either way, and pictures you uploaded before today carry on working exactly as they did.
Jump to a section
On Amazon Web Services — aws.amazon.com
Amazon rents out storage space by the month, for very little money, and anybody can open an account and use it. You are going to make one place in that storage that belongs to you, and let this site builder put your pictures and videos into it.
Four names you will see on Amazon's website, in plain words:
Three kinds of file, one bucket
Your logo, the picture behind a heading, the background of a section or a button. Small, and there are many of them.
The photograph of each thing you sell. Bigger, because they need to stay sharp when somebody looks closely.
Much bigger than either of the above. One video can be larger than every picture on your site put together, which is the real reason this storage is worth having.
What Amazon charges. You pay for how much you keep and how much is sent out to visitors. Both are charged by the gigabyte, and both are cents rather than dollars at the size of one small business website. An empty bucket costs nothing at all.
Amazon asks for a card when you open the account, and they do charge it, so this is a real bill in your name — a small one, but yours. Set a billing alert while you are in there if that would let you sleep better.
aws.amazon.com → Create an AWS Account
Skip this part if you already have one. An ordinary Amazon shopping account is not the same thing, so you probably need to do this even if you buy from Amazon every week.
Use a business email you will still have in five years, not a personal one you might stop using.
Amazon takes a small amount and refunds it, to check the card is real.
The free plan is the right one. You can change it later if you ever need to.
This account will hold your website's files and a card. Two-step sign-in means a stolen password alone is not enough to get in.
This is the one part people get stuck on
A bucket name has to be unlike every other bucket name in the world, not just unlike yours. Short, obvious names such as "photos" or "media" were taken years ago. A name can never be changed afterwards, so choose it once and write it down.
So "Hill Street Bakery" becomes hill-street-bakery-media-4417. The four numbers are what make it unlike anybody else's.
No capital letters, no spaces, no underscores. Amazon refuses those.
You will type this same name into three different places, and they all have to match exactly.
Everywhere below that says your-bucket-name, type your own name instead. Nothing will work if the one in the permission does not match the one on the bucket, letter for letter.
console.aws.amazon.com → S3
Type S3 into the search box at the top and pick it from the list.
If Amazon says the name is already taken, change the four numbers at the end and try again. That is all that is wrong.
If most of them are in the United States, US East (N. Virginia) us-east-1 is the usual choice. Write down which one you picked; you will need it at the end.
It means nobody can go rummaging through your storage directly. You will decide in the next part how your pictures are allowed to be seen, and that decision is the one that matters most.
console.aws.amazon.com → CloudFront
This is the first of the two ways to let your pictures be seen, and it is the one that also makes them load quickly for somebody on the other side of the country. If you would rather not set this up, do the next part instead — but you must do one of the two, because a bucket that nobody is allowed to read will take your pictures and then show none of them.
Distribution is simply Amazon's word for one of these delivery setups.
Origin means where the real files are kept.
This is what lets the delivery service read a bucket that is otherwise shut to everybody.
A yellow bar appears saying the bucket policy needs updating, with a Copy policy button. Click it, go back to your bucket, open the Permissions tab, edit Bucket policy, paste, and save. That one policy says the delivery service may read your files, and says nothing about anybody else.
It looks like d111111abcdef8.cloudfront.net. You will need it at the end. A new one says Deploying for a few minutes, which is normal.
console.aws.amazon.com → S3 → your bucket → Permissions
This is the second of the two ways, and it is the quicker one. Instead of putting a delivery service in front of your bucket, you tell the bucket itself that anybody may read a file out of it. Do this or the delivery service above, not both.
Here is the honest trade. Doing it this way takes about five minutes and needs nothing new set up. What you give up is that anybody who knows the exact address of one of your files can open it, without going through your site — which is no worse than it sounds, because every picture on your website is already there for anybody to look at. Your pictures also load a little more slowly for somebody far away, because there is no delivery service helping. Nothing else in your bucket is affected: only reading is allowed, and only reading.
Leave the two that mention access control lists ticked on. Those are an older way of granting access that you are not using, and leaving them on keeps one more door shut.
confirm when Amazon asks you to.Amazon asks because this is a real change. You are allowing the next step to work; nothing is readable yet.
Change your-bucket-name-0000 to your real bucket name, in both the line that has it. Everything else stays exactly as written.
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "AllowPublicReadOfPictures",
"Effect": "Allow",
"Principal": "*",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::your-bucket-name-0000/*"
}
]
}In plain words: anybody may read a file out of this bucket, and that is the only thing anybody may do. Nobody can list what is in it, nobody can add anything, and nobody can delete anything. Only the key you make in the next part can do those.
Amazon now shows your bucket as Publicly accessible. That is what you asked for and it is correct.
console.aws.amazon.com → IAM
This is the careful part, and it is worth going slowly. You are about to give this site builder a key to your Amazon account. The permission below means that key can put a file into your one bucket, read one back, and delete one — and absolutely nothing else, anywhere.
easy-life-sites.So that a year from now it is obvious what this is and where it is used.
This user is for a program, not a person. It never needs to sign in anywhere.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:PutObject",
"s3:GetObject",
"s3:DeleteObject"
],
"Resource": "arn:aws:s3:::your-bucket-name/*"
},
{
"Effect": "Allow",
"Action": "s3:ListBucket",
"Resource": "arn:aws:s3:::your-bucket-name"
}
]
}easy-life-sites-media and create it.What that permission really says, in order: put a file in, read a file back, delete a file, and list what is in there — and only inside the one bucket you named. It cannot make or delete buckets, cannot open any other bucket, cannot see your bill, cannot change your account, and cannot spend your money. If that key were ever stolen, that list is the whole of what a thief could do with it.
The list permission is what lets the Picture Library in the builder show the pictures you have already uploaded.
console.aws.amazon.com → IAM → Users → easy-life-sites
That is what this site builder is, as far as Amazon is concerned.
There is an access key ID, starting with AKIA, and a secret access key. Amazon shows the secret once and never again.
It is a password. Do not email it, do not put it in a message, do not save it in a document. The only place it goes is the settings box in the next part.
Your own account page here → the storage card
Four things go in, and then you are finished.
Exactly as you typed it on Amazon.
The one you chose when you made the bucket, such as us-east-1.
The d111111abcdef8.cloudfront.net name. Leave this empty only if you let the world read your bucket instead, because one of those two has to be true. When you save, this page writes a small test file into your bucket and then tries to read it back the way a visitor's browser would. If a browser would be turned away, it tells you so and refuses to save, rather than letting you find out after you have uploaded a picture.
The secret is stored the way a password is stored, and is never shown back to you or to anybody else. Saving it is the last step: from that moment, everything you upload goes into your own storage.
Pictures you uploaded before today carry on working exactly as they did. Nothing already on your site moves or breaks.
The four things that actually go wrong
Somebody in the world has that name. Change the four numbers at the end and try again.
Nearly always the bucket name in the permission does not match the real bucket name. Open the policy and compare them letter for letter.
There are two causes and they are easy to tell apart. If you set up a delivery service, it is probably still saying Deploying, which takes a few minutes — wait, then load the page again. If you did not set one up, then nobody is allowed to read your bucket, which is this exact problem: the picture really is in your storage, and every browser is turned away from it. Go back and do one of the two parts above, either the delivery service or letting the world read your bucket, and then save your settings again.
Clear the settings on your account page here and the site builder goes back to keeping your files the way it did before. Your bucket and everything in it stays exactly where it is, untouched, because it is yours.