Twenty years ago, when Eric Baker tried to buy a secondhand ticket to “The Lion King” on Broadway, the high prices and hassle of the experience gave him a business idea: What if there were an easier way to buy and sell tickets online?

That idea became StubHub, a secure secondary marketplace for tickets founded by Mr. Baker and a partner, Jeff Fluhr, in 2000, when they were students at Stanford’s business school. After a rift between the founders, Mr. Baker left StubHub and in 2006 created a rival, Viagogo, which has become a strong presence in Europe. In 2007, eBay bought StubHub for $310 million, and Mr. Fluhr left the company.

Now Mr. Baker is bringing the two together. On Monday the companies announced that Viagogo, the smaller of the two, would acquire StubHub for $4.05 billion in a deal that would create a behemoth in the growing market for ticket resales.

“We bring international coverage, and StubHub has got phenomenal coverage in the U.S.,” Mr. Baker said in an interview. “When you put the two together, you’re giving fans access to almost any ticket anywhere, in any language and in any currency.”