It's very easy to solve it without url hacks, with CloudFront help. - Create s3 bucket, for example: react. - Upload simple index.html file. - Create cloudfront distributions with these settings: - **Default Root Object**: index.html - **Origin Domain Name**: s3 bucket url, for example: react.s3.amazonaws.com - Add custom error page with these settings: - **HTTP Error Code**: 403: Forbidden - **Customize Error Response**: Yes - **Response Page Path**: /index.html - **HTTP Response Code**: 200: OK