Montreal-based gaming company Amaya Gaming Group Inc. has agreed to purchase privately held Oldford Group, the owner of online poker websites PokerStars and Full Tilt Poker, for $4.9 billion.

The transaction will turn Amaya into the biggest online gambling company in the world.

Those two websites are the world's most popular and profitable online poker brands, the companies claim, with more than 85 million registered players on desktop and mobile devices.

The company has made large inroads in a time when a lack of clarity in U.S. law with regards to online gambling has kept the industry in the shadows. But the companies have also lost a few hands along the way, with the two poker websites agreeing to pay more than $700 million in fines to the U.S. Justice Department in 2012 to settle allegations they were engaged in illegal activity.

The businesses in the new company pulled in $1.3 billion in revenue last year. 

The boards of directors of both companies have unanimously approved the deal.