David Moyes' side moved off the bottom of the table and it was no more than they deserved after dominating possession for long periods and looking the more threatening.
Johnson could only deflect a low cross from Leon Osman past Blues keeper Ben Foster nine minutes into the second half and, in injury time, Cahill turned in Leighton Baines' centre.
Everton's performance belied their lowly position in the Barclays Premier League, with Mikel Arteta, Leon Osman and Marouane Fellaini controlling the midfield, and had enough opportunities to have been in front before Johnson's error put them on the way to victory.
This setback ended Birmingham's hopes of setting a new club record of 19 successive league games at St. Andrew's without defeat.
City, who have now won only two of their last 17 league games, lacked any cohesion or fluency and once again there was a lack of a cutting edge in the final third of the pitch.
Everton made a promising start and knocked the ball around in confident style despite their current precarious position.
Cahill got on the end of a deep cross from Baines, after he had been found in plenty of space by Fellaini, but his downward header was collected by Ben Foster.
Everton were finding plenty of space on their left flank and a cross from Ayegbeni Yakubu picked out the run of Seamus Coleman, but his header back across goal was cut out by Foster.
Yakubu dragged a low shot across the face of goal as City were pinned back in their own half and Cahill could not hide his frustration when heading wide from a Baines centre.
Birmingham did not threaten until the 26th minute but Cameron Jerome could have put them ahead.
Sylvain Distin could only back-head a chip from Barry Ferguson into the path of Jerome and the former England Under-21 striker took the ball in his stride but poked his shot well wide.
Everton were soon back on the offensive and a slip by Roger Johnson left Yakubu with a clear run at goal.
But Foster managed to get a hand onto his cross-shot and Liam Ridgewell was behind him to complete the clearance.
Everton were playing with great fluency and a run by Yakubu carved out another chance for Osman. But after turning inside the area, he wasted another decent opportunity by curling his shot over Foster's crossbar.
Everton were soon back on the offensive after the interval and Johnson threw himself forward in typical fashion to block a shot from Osman.
The Blues fans tried to rally their team but after 54 minutes Everton went ahead through an own goal by Johnson.
Osman sent a low first-time cross to the near post which looked to be covered by Foster but Johnson got to the ball ahead of him and could only deflect it into his own net.
It was Everton's first away league goal of the campaign and no more than they deserved given their dominance.
City tried to retaliate and appealed in vain for a penalty when Carr was challenged by Baines.
McLeish made his first change after 70 minutes with Nikola Zigic replacing Keith Fahey as City reverted to a 4-4-2 formation.
Bowyer had a good chance after Scott Dann headed back across goal but the veteran midfield went for the spectacular finish when he had more time at his disposal and volleyed over the bar.
Moyes brought on John Heitinga for Yakubu as Everton tried to protect their lead, while Jerome made way for Matt Derbyshire.
Then in injury time Cahill made it 2-0 when he headed in a centre from Baines.