Yorkshire 210 and 166 for 3 (Ballance 57*, Lyth 44) lead Kent 296 (Robinson 103, Crawley 81) by 80 runs
Gary Ballance posted Yorkshire's first half-century of the game to keep his side in contention against a Kent side buoyed by a second County Championship century of the season by rookie keeper-batsman Ollie Robinson.
Having conceded a first innings deficit of 86 runs, Yorkshire closed on 166 for 3 after 46 overs of their second innings to lead by 80 runs going into the third day of this finely poised Division One game in Canterbury.
Ballance, who won the last of his 23 Test caps in July 2017, went in at the close unbeaten with 57 and having added 27 with fourth-wicket partner Jack Leaning, who was not out 11.
After dismissing Kent for 296, Yorkshire started their second innings shortly before tea but soon lost Harry Brook, caught behind when prodding outside off at one from Fred Klaassen.
Left-handed pairing Adam Lyth and Ballance took their total through to 82 before Lyth, well set on 44, nibbled at a Mitch Claydon leg-cutter to be caught at the wicket.
Tom Kohler-Cadmore became the final casualty of the day when he attempted to force off the back foot against Daniel Bell-Drummond to be held in the gully.
Kent, who had earlier resumed on their overnight score of 130 for 4, only had themselves to blame for missing out on a third batting bonus point by only four runs.
Robinson and Zak Crawley batted on for half an hour without alarm to extend their partnership's value to 86 before Crawley fell for 81 to Steven Patterson's fourth ball of the day. In aiming to work a length ball to mid-wicket, the willowy right-hander found a leading edge to loop a comfortable return catch to the bowler.
Robinson, Kent's 20-year-old understudy keeper, drove nicely all morning to his first 50 at Canterbury from 103 balls with six fours and with only three scoring leg-side shots.
After a sticky start, Alex Blake cover drove Patterson for four to raise Kent's 200 and a batting bonus point, then the left-hander's backward cut through point against Dom Bess also went to the ropes to level the scores.
With his score on 22, Blake took a hefty blow on the head after ducking into a Duanne Olivier bouncer but continued after treatment and replacing his helmet. He swayed out of the way nicely when Olivier followed up with another bumper.
Olivier maintained his aggression and was unlucky not to remove Robinson on 71 when an edged glance flew behind to Jon Tattersall, only for the Yorkshire gloveman to spill the chance.
Robinson and Blake added 50 before Blake, having been dropped at short leg the previous delivery, edged to slip to give Kohler-Cadmore the fourth of his six out-field catches - equalling the Yorkshire record set by Ellis Robinson against Leicestershire at Bradford in 1938.
With Kent's Robinson edging toward three figures, Harry Podmore miscued to mid-on to gift Bess a wicket, then Matt Milnes nicked off against Olivier.
Robinson finally reached his 177-ball ton with a scampered single to mid-off, but holed out soon after enabling Yorkshire to polish off the home tail.