Ignition switch or starter relay. When it won't start, you need to put a voltmeter on the small wire on the starter solenoid and see if you have +12V when the key is turned. If you see +12V, then the starter should turn.So recently bought a 2007 3.5l g6 and it was starting fine when I first bought it but it needed a neutral safety switch so I already planned to replace it. So one day it just wouldn't start checked all the fuses and the battery and all of that was fine.The security light wasnt on. But it wouldn't crank at all tried jumping it and nothing. So I ended up replacing the neutral safety switch hoping it would work since I needed a new one but nope. Ended up pulling starter off so I decided to test it and it ended up being bad because it wouldn't work sometimes. I replaced the starter with a working one and it still doesn't start. Checked all the wiring to the starter and it seemed fine.Then just the other day it started up.I just dont know what it could be and was wondering if anyone could help or give ideas on what it could be.
If no +12V, then pull the starter relay from the underhood fuse block and probe it to see if you see +12V across the coil (input) terminals when the key is turned to crank. If no +12V there, then the issue is upstream in either the computer or the ignition switch.
If you see +12V on the coil, then the relay is bad. Try swapping another relay from the same fuse box and see if cranks then. If so, get a new relay.
After that, you will need to start probing the ignition wiring and computer wiring. But try the relay and starter solenoid first.