Need help with 2003 GMC Yukon Denali

So one day I was going to work I went to go turn on the car and boom, it wouldn’t turn on. I’ve had this battery for around 1.5 years and was working fine untill that point. So I thought I was the battery so I went and got a new one. The first day the car worked fine. But then the second day it when it turned bad. The car would start but after 20 secs or so it would turn off, again the car would start fine. So I start pull out of my drive way and go to a four way stop and boom the car turns off again. Anytime I stop or if I’m parked it stop, help

Can you identify the area of the car from which that “boom” noise is emanating?
:thinking:

if you remove boom from the previous paragraph it makes no difference in the information conveyed. i went to turn on the car and it would not. vs boom, it would not. maybe the OP means to say boom like an exclamation point? like boom, nothing happened.

Perhaps, but I think we need the OP to clarify matters for us before proceeding with any specific advice. As Sgt. Joe Friday used to say, “Just the facts, Ma’am”.

Also, exactly what does this mean? The starter cranks? or no sound at all?

As I understand it, the current problem is your car will crank and start up ok, but it turns off after running a few minutes? Right? It turns off by itself when you come to a stop at the stop sign. hmm … my guess is the ignition switch is faulty. Try driving your car with just a single key in the ignition switch, no key chain, nothing dangling. If that seems to improve the situation, you’re probably looking at the cost of a new ignition switch.