Create a Gateway endpoint
- Open the VPC console, choose Endpoints → Create endpoint.
- Name tag:
s3-gwe. Type: AWS services.
- In Services, filter by
s3 and choose com.amazonaws.<region>.s3 with type Gateway.

- VPC: choose VPC Cloud.
- Route tables: select RT Private Cloud (the table associated with the 2 private subnets – not the main table).
- Policy: keep Full access. You will restrict access with an endpoint policy in section 5.

- Scroll down and choose Create endpoint.

- The endpoint s3-gwe is created with status Available.

- Open Route tables → RT Private Cloud → Routes. A new route has been added automatically: destination is the S3 prefix list (
pl-...) and target is the gateway endpoint (vpce-...).

The route table has no 0.0.0.0/0 route, so instances in these subnets cannot reach the Internet. Only S3 traffic (matched by the prefix list) leaves the VPC – privately, through the gateway endpoint.