A penalty from debutant Olly Barkley ensured Gloucester scored a 24-20 victory over Harlequins at Kingsholm.
Gloucester made it back to back victories to knock Harlequins off the top of the Premiership table after fly-half Chris Malone had an off day with the boot.
Malone missed out on 10 first-half points with some wayward kicking, failing to land two penalties and two conversions.
Olly Barkley made his debut for the Cherry and Whites since his move from west country rivals Bath.
Barkley had missed the opening two games as he recovered from a fractured bone in his left wrist sustained during England's summer tour to New Zealand.
He started at inside centre with skipper Mike Tindall switching to outside centre and Matthew Watkins moving to wing while in the pack Alasdair Strokosch came in at blindside flanker.
Quins' only change from the side that beat Bristol 31-13 saw Malone return from injury for his first start of the season to replace Waisea Luveniyali. The Fijian half-back started from the bench where he joined Mark Lambert who was back from a long term injury.
Wing David Strettle's weaving run set up Quins' opening score which full-back Mike Brown completed against a slack Gloucester defence to touchdown after 12 minutes.
Malone, who had already missed two penalty attempts from close to the left touchline, was off target with the conversion.
The fly-half missed a second conversion attempt a couple of minutes later after his half-back partner Danny Care had hacked on then collected 15 metres from the line to race away for the visitors' second try.
With 15 minutes of the half remaining Gloucester took a quick tap penalty with the ball being fed through fly-half Willie Walker and Tindall for full-back Olly Morgan to score in the corner.
Walker missed the touchline conversion but Quins countered almost immediately with Malone finally finding the target with his third penalty attempt to give the visitors a 13-5 interval lead.
Gloucester reduced the arrears to a couple of points early in the second half though with Walker kicking a penalty and slotting between the uprights a 35-metre drop goal.
Midway through the half Quins skipper Will Skinner was sent to the sin-bin by referee Rob Debney and Walker kicked the resultant penalty to put Gloucester in front for the first time in the game.
The home side took advantage of the extra man when replacement scrum half Rory Lawson took a quick tap penalty. He fed No.8 Luke Narraway who set blindside flanker Alasdair Strokosch on a 40 metre dash for the line.
Walker added the extras but Quins came back quickly as Malone cut back inside to touchdown before adding the conversion to leave the visitors trailing by a point with 15 minutes remaining.
Barkley, who had taken over the kicking duties with Walker having been replaced, missed a 40-metre penalty from in front of the posts but was on target minutes later from out on the left to seal the game.
Gloucester (5) 24 Harlequins (13) 20
Gloucester: Tries: Morgan, Strokosch. Cons: Walker. Pens: Walker 2, Barkley. Drop Goals: Walker.
Gloucester: Morgan, Watkins, Tindall, Barkley, Vainikolo, Walker, Cooper, Wood, Azam, Nieto, James, Brown, Strokosch, Hazell, Narraway.
Replacements: Lamb for Walker (63), R. Lawson for Cooper (53), Dickinson for Nieto (14), Titterrell for James (68), Bortolami for Brown (63), Buxton for Hazell (53).
Not Used: Foster.
Harlequins: Tries: Brown, Care, Malone. Cons: Malone. Pens: Malone.
Harlequins: Brown, Strettle, Tiesi, Turner-Hall, Monye, Malone, Care, Jones, Fuga, Ross, Kohn, Robson, Robshaw, Skinner, Easter.
Replacements: J. Evans for Care (30), Botha for Fuga (56), Lambert for Kohn (56), Guest for Robshaw (56). Not Used: Gomarsall, Williams, Luveniyali.
Sin Bin: Skinner (58).
Att: 12,216
Ref: Rob Debney (Leicestershire).