Coming off one of the worst games of his career, Maynard threw an interception on the first series of the game and repeatedly picked himself up off the turf at Memorial Stadium after getting drilled by the Bruins defense to help the Golden Bears (2-4, 1-2 Pac-12) end their three-game losing streak.
Johnathan Franklin rushed for 103 yards for UCLA, which lost for the second time in three games and is likely to fall out of the rankings again.
By beating the Bruins (4-2, 1-2) at home for the seventh straight time, the Bears might have also decreased some of the pressure on coach Jeff Tedford.
Tedford had come under criticism from some alumni and boosters recently over the team's poor start.
Richard Rodgers caught seven passes for 129 yards while Keenan Allen caught a pair of touchdowns and finished with eight receptions to move into third place on Cal's career list.
Maynard, who completed only 9 of 28 passes in last week's loss to Arizona State, was almost flawless against UCLA. He completed 13 consecutive throws during one stretch in the second half and finished 25 of 30 for 295 yards.
The Bears' senior quarterback also scored on a 1-yard keeper in the fourth quarter following a 42-yard interception return by safety Mike Lowe.
As sharp as the offense was, it was Cal's defense that made the difference.
UCLA quarterback Brett Hundley threw four interceptions, three by Bears cornerback Kameron Jackson. The Bruins, who had only one turnover in their previous two games, also fumbled twice.
Hundley, the redshirt freshman who has looked strong running UCLA's spread offense, never found his rhythm. He had a season-high 31 completions and passed for 253 yards and two touchdowns, but couldn't prevent the Bruins from remaining winless at Memorial Stadium since 1998.
C.J. Anderson rushed for 151 yards, 68 on a touchdown run in the fourth quarter to extend Cal's lead to 26 points.
The ending was in sharp contrast to the opening drive for UCLA.
The Bruins got creative when Hundley threw a 4-yard touchdown pass to Cassius Marsh, a defensive end who lined up on the left side of the offensive line then ran a short out pattern. It's a formation UCLA has used previously this season, but the first time Marsh, a 275-pound senior, has scored.
Cal responded with a 26-yard field goal by Vicenzo D'Amato then took the lead on Maynard's 9-yard touchdown pass to Anderson midway through the second quarter. Maynard got the drive started with a 42-yard completion to tight end Rodgers then capped it with the throw to Anderson, who beat safety Tevin McDonald on an slant pattern.
That came after Hundley was charged with a fumble after his short pass in the left flat to Jordan James was ruled a lateral and recovered by Cal's Nick Forbes.
After UCLA kicker Ka'imi Fairbairn missed a 46-yard field goal attempt, the Bruins forced a punt but Kenny Orjioke ran into return man Steven Manfro as Manfro was calling for a fair catch. The ball hit Orjioke in the back and Cal pounced on it.
Five plays later, Maynard connected with Allen for an 8-yard touchdown on an inside slant play similar to the one run by Anderson.
The Bruins committed their third turnover of the first half when Hundley threw an interception in the end zone after the intended receiver stopped his route well short of the goal line.
Maynard threw touchdowns on Cal's first two drives in the second half to push the lead to 29-14.
UCLA pulled within 29-17 on Fairbairn's 30-yard field goal early in the fourth quarter, but Cal's defense came up with two more interceptions to secure the win.