You need to check the permission of your S3 bucket. It should allow "Upload/Delete".
In addition, you should set up CORS configuration (CORS: Cross-Origin Resource Sharing)
(for your bucket, go to Properties ==> Permissions, then click on 'Add CORS Configuration')
The file should have something like this:
<?xml version="1.0" encoding="UTF-8"?>
<CORSConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
<CORSRule>
<AllowedOrigin>http://localhost:3000</AllowedOrigin>
<AllowedMethod>GET</AllowedMethod>
<AllowedMethod>POST</AllowedMethod>
<AllowedMethod>PUT</AllowedMethod>
<MaxAgeSeconds>3000</MaxAgeSeconds>
<AllowedHeader>*</AllowedHeader>
</CORSRule>
</CORSConfiguration>
Here it allows my localhost to post files to this bucket.