Car clicks while trying to start, but starts most times until recently, on 2003 GMC Envoy

Could it be the starter? We already replaced the alternate rand the fuel pump, is there a sensor? It is also idlying a little rough

Asked by for the 2003 GMC Envoy
Definitely have the starter checked, if there is an abundance of corrosion on it, it's on it's way out. Tap the starter with a hammer and try to start it, if it starts then it's most likely the starter going bad.