Rough idling on my Mazda 626

the idling is rough and if I put the air conditioning on, the engine stalls. Sparks plugs are fine,Spark plugs wire are fine too! changed the fuel filter, no vacuum leak, egr seems fine. I am at a loss. Please help!

You did not state the year and mileage but whenever there is an engine performance problem a compression test should always be performed. You always weed out a potential mechanical fault first and this should be done even on a fairly new car with low miles.

If the compression is fine (as in 175 and up, etc) and assuming this is a distributor equipped model in which the timing is correct, then you might suspect an Idle Air Control valve problem.

As OK4550 says, it will help a lot to know the year. A 1989 Mazda 626 would have a much different set of engine control hardware than a 1999. First guess would be a problem with fuel mixture or an intermittent ignition problem, but that’s pretty generic. If it’s a 1989 or thereabout, there is an idle adjust screw on top of the air cleaner assembly that may provide some probably temporary relief, but tweaking it likely won’t fix the underlying problem. I seem to recall that there is a cover screw over the actual idle adjust screw, but after 20 years or so, I wouldn’t bet on it still being there.

It is a 1998 4 cyl with 106000 miles on it!I noticed that the ground wire coming out of the battery is not attached to anything. Could this create related trouble! I will check the IAC and the MAF.

t is a 1998 4 cyl with 106000 miles on it!I noticed that the ground wire coming out of the battery is not attached to anything. Could this create related trouble! I will check the IAC and the MAF.

I noticed that the ground wire coming out of the battery is not attached to anything. Could this create related trouble!

You just bet it could. The only reservation I’d have is how the car could possibly be started and run at all with no battery ground. I’m guessing that there really is a ground connection, but maybe not a good one

Hooked the yellow ground to the car body. Cleaned both the Idle Air Control and Mass Air Flow sensor. The IAC was a little black but I do not see any improvement! Is it because you are supposed to reset the computer and if yes how do you do it? What else could be wrong??? This is killing me!