Previously, writers Christopher Markus and Stephen McFeely have mentioned that the scene went through multiple changes throughout the scripting process. Ultimately, they decided to go with Black Widow’s death after consulting some of the female crew members, who felt that it would be a heroic and empowering sendoff to the intriguing character. Markus also said: However, it looks like there was a version of the script where the scene plays out completely differently, and not just in terms of who lives or dies either. Speaking at ACE Comic-Con (via Screenrant), Jeremy Renner, who plays Hawkeye in the Marvel Cinematic Universe revealed that the Vormir sequence we saw in theatres was part of extensive reshoots. The original version is much more elaborate and even involves Thanos launching an attack on the planet. Renner said:

This isn’t very hard to believe, as even in the theatrical edition there’s a scene where we see Nebula trying to send a message to Black Widow and Hawkeye upon realising that Thanos knows about the Time Heist. While this amounted to nothing in the final cut, perhaps Nebula’s quick thinking helped Black Widow and Hawkeye out in the version where Thanos attacks. Having said that, I love the more personal approach of the final cut. It allows the two best friends to have an intimate moment before doing what needs to be done.

Black Widow and Hawkeye s Suicide Attempt in Endgame Was Initially Completely Different - 83