---
title: "Comment by Stefan Olaru on \"Upload Files to S3 Using API Gateway: A Step-by-Step Guide\" | Hashnode"
description: "Nice, love the simple code-less way! One question though: how to prevent S3 object overwrite?"
url: "https://hashnode.com/posts/upload-files-to-s3-using-api-gateway-a-step-by-step-guide/65e03552ecf3eead2326cca0/comment/65e07d67953415349036049c"
---

[Discussion](https://hashnode.com/posts/upload-files-to-s3-using-api-gateway-a-step-by-step-guide/65e03552ecf3eead2326cca0)

Comment [Upload Files to S3 Using API Gateway: A Step-by-Step Guide](https://hashnode.com/posts/upload-files-to-s3-using-api-gateway-a-step-by-step-guide/65e03552ecf3eead2326cca0)

[Stefan Olaru](https://hashnode.com/@stefanolaru)

[Feb 29, 2024](https://hashnode.com/posts/upload-files-to-s3-using-api-gateway-a-step-by-step-guide/65e03552ecf3eead2326cca0/comment/65e07d67953415349036049c)

Nice, love the simple code-less way!

One question though: how to prevent S3 object overwrite?

[Enrico Portolan](https://hashnode.com/@enricop89)

[Mar 1, 2024](https://hashnode.com/posts/upload-files-to-s3-using-api-gateway-a-step-by-step-guide/65e03552ecf3eead2326cca0/comment/65e07d67953415349036049c#reply-65e1ed7068da81daedf88d81)

Probably the easier way is to enable object versioning in the bucket
