South African Ruan Pienaar was the hero as Ulster clinched a Heineken Cup quarter-final home tie with a brilliant 22-19 victory at Leicester.
The scrum-half scored all Ulster's points in an epic battle at Welford Road to ensure his side finished top of Pool Five with six wins from six matches.
Pienaar scored a try, kicked the conversion and landed five penalties, including two monsters from inside his own half, in the final pool match.
The Tigers, who will have to travel in the quarter-finals after their first home defeat in the competition since 2006-07, scored a try through winger Niall Morris and fly-half Toby Flood converted and also slotted four penalties.
Pool leaders Ulster started the game two points ahead of Leicester and while both teams had already qualified the prize for the winners was a crucial home tie.
Ulster made two changes from the side that beat Montpellier, bringing in prop Callum Black and back rower Roger Wilson, while Leicester recalled centres Anthony Allen and Matt Smith and locks Ed Slater and Graham Kitchener.
Ulster had won all five of their pool matches while Leicester had lost one - at Ulster - and the previous five meetings between the sides had gone the way of the home side.
The Tigers, backed by a vociferous 24,000 sell-out crowd, made a barnstorming start to a ferocious contest and led 6-0 after 11 minutes but Ulster pegged them back and the sides turned round level at 9-9 at half-time.
Flood kicked three penalties but, crucially, missed the easiest of the lot when he hooked the ball wide of the left post in the 35th minute.
Pienaar kept his side in the game with three penalties of his own, the third a monster from two metres inside his own half, before f ly-half Paddy Jackson was just wide with a snap drop-goal attempt in the 40th minute.
Leicester just about edged the half but chances were few and far between and their best opportunity came in the 20th minute when Kitchener burst free from a ruck 40 metres out and looked certain to score - until full-back Jared Payne collared him just short of the line.
Ulster's best chance came two minutes before the interval when they surged down t he right after robbing Tigers scrum-half Ben Youngs.
Winger Andrew Trimble latched onto the kick ahead and fed Payne but Trimble was adjudged to have put a foot in touch.
Flood kicked penalties in the 4th, 11th and 23rd minutes, the first and last coming after Ulster were penalised at scrums where the Tigers had a definite edge.
Pienaar replied with penalties in the 16th, 27th and 31st minutes and with Leicester losing number eight Jordan Crane and full-back Mathew Tait to injury, Ulster finished the half the stronger. The pair were replaced by Steve Mafi and Scott Hamilton.
Flood restored Leicester's lead seven minutes after the interval when he landed a 32-metre penalty after Ulster had again offended at a scrum.
And 12-9 became 19-9 two minutes later when Morris scored the first try of the match, brilliantly converted from the right touchline by Flood.
It came after great work by hooker Tom Youngs and winger Vereniki Goneva in the loose. Flood chipped down the right and Morris fended off a tackle to score in the corner, the try being awarded by the TV official.
Minutes later it was all hands to the pump for Leicester, who failed to deal with a high ball and were pinned on their own line, with Pienaar coming close to scoring before the Tigers pinched the ball and half cleared their lines.
Ulster, however, kept the pressure on and won a penalty which Pienaar kicked in the 57th minute to make it 19-12.
And they were level a minute later after another high ball. Although Leicester dealt with this one Flood's clearance was charged down by Pienaar who followed up for an easy try before converting from the right touchline.
Pienaar then kicked another monster penalty, from a metre inside his own half, in the 69th minute to put Ulster ahead for the first time and Ulster withstood a Tigers o nslaught before finishing strongly.
Ulster captain Johann Muller hailed Ruan Pienaar after the South African's efforts clinched his side a famous victory at Leicester Tigers and a home tie in the Heineken Cup quarter-finals.
Scrum-half Pienaar scored all of Ulster's points in the 22-19 win over the Tigers at Welford Road and the 1999 champions will now play Saracens in the last eight at Ravenhill in April.
Piennaar not only kicked five penalties and a conversion but also scored the crucial try after charging down a clearance from Leicester fly-half Toby Flood in the 58th minute to level the scores at 19-19.
His winning penalty, in the 69th minute, was from a metre inside his own half, his second monster kick of the game.
Muller said: "It seems like it's happening every week, when he scores all the points.
"I came here with him yesterday to do kicking practice and he did not miss one all day. He was outstanding and kicked them from 60, 62 metres. From a captain's point of view it gives you a lot of confidence.
"A huge amount of credit to him and it doesn't just happen. He puts a huge amount of work in, he puts hours and hours into his kicking and it's wonderful when it pays off."
Ulster's win means they top Pool Five with six wins out of six and in April will have a chance to avenge last season's quarter-final defeat at Saracens.
This time, however, they will have home advantage, and Muller said: "We came here to get a home quarter-final.
"Sarries totally outplayed us last season. They are a great side and don't mind going away to get a result.
"It's two months away and at this stage we will just enjoy the moment. We have not achieved anything yet and there's a huge amount of work left if we are to achieve something."
Leicester led 19-9 after a 49th-minute try by winger Niall Morris had put them in the driving seat.
But Flood, who converted the try and kicked four penalties out of five, cost Leicester dear when his clearance was charged down by Pienaar nine minutes later.
Richard Cockerill, Tigers' director of rugby, said: "We're disappointed with the result, but it was a good game.
"It was very tight margins and we dropped the wrong side of those margins. Ten points up, we needed to control the game better but we did not manage the back field as well as we would have liked and they exposed us.
"To lose to a charge-down kick is disappointing but you make your own luck.
"I am not going to criticise us. The luck of the draw fell their way tonight and that happens in sport. It wasn't for a lack of effort. We played some good stuff and you just have to take it on the chin."
Leicester, who suffered their first home defeat in the competition since 2006-2007, face a quarter-final away to a French team, either Toulon or Clermont Auvergne, and should have their England and British Lions pair Manu Tuilagi and Geoff Parling back by then.
"At the moment it's probably Toulon, tomorrow it may be Clermont who have an average home record, what is it, 73 games unbeaten," said Cockerill.
"We are in the quarter-finals and we have suffered a lot of adversity (through injuries), so that's not a bad effort from us."