The 1967 work painted in three 11 x 14 inch (28 x 36cm) frames is thought to be based on photographs taken by Bacon's friend John Deakin.
The painting is one of only five known triptychs of Dyer in the small scale format.
It was the first time the piece had appeared at auction, having been in a private collection since 1970.
Sotheby's said the sale beat Bacon's previous record of £23m for a work in the format.
"The driving force tonight was passion," Sotheby's Cheyenne Westphal said.
"The Bacon was bought by collectors who truly wanted to own it. It was a completely private market that came from virtually every side of the world and people wanted to own this wonderful piece and live with it."
Sotheby's senior international specialist in contemporary art Oliver Barker added: "The story between Francis Bacon and George Dyer is actually extraordinary, they actually met because George Dyer broke into Francis Bacon's mews house and they became friends, lovers and extremely close.
"Very sadly George Dyer committed suicide on the night of Bacon's biggest and most important exhibition at the Grand Palais in Paris in 1971 and that was just for Francis one of the most horrific things."
Haunted by his loss, Bacon continued to paint Dyer for some years, producing his famous Black Triptychs in the 1970s.
Other sales at the contemporary auction included a record £8.5m  for Scottish artist Peter Doig for his oil painting Country-rock (wing mirror), and Andy Warhol's Nine Multicoloured Marilyns which sold for £4.6m.
A small-format Francis Bacon triptych of his lover George Dyer has sold for £26.7m at a London auction.