The Conservatives won the Newark by-election after holding off a challenge from UKIP.
Tory candidate Robert Jenrick polled 17,431 votes to beat UKIP’s Roger Helmer, who finished second with 10,028 votes.
Labour finished in third while the Liberal Democrats were a dismal sixth.
The election was needed after the resignation of Patrick Mercer , who quit over a cash-for-questions scandal.
Following their success in the recent European elections, there was growing belief that UKIP could take their first ever Westminster seat.
In the weeks leading up to polling day, several heavyweight members of the three main parties, including all three party leaders, visited the constituency several times to help support their candidates in the face of growing dissatisfaction from the electorate and the rise of the protest vote for UKIP.
In the end, Mr Jenrick won by over 7,000 votes but UKIP leader Nigel Farage said he was delighted with his party’s showing.
Full result: Robert Jenrick (Con) 17,431; Roger Helmer (UKIP) 10,028; Michael Payne (Lab) 6,842; Paul Baggaley (Ind) 1,891; David Kirwan (Green) 1,057; David Watts (Lib Dem) 1,004; Nick The Flying Brick (Loony); Andy Hayes (Ind) 117; David Bishop (BP Elvis) 87 ; Dick Rodgers (Stop Banks) 64.