Nearly two years after announcing their proposed merger, T-Mobile (TMUS -0.06%) and Sprint (S) are just inches away from closing the deal. The two companies have successfully navigated multiple obstacles, securing approval from regulators at the Federal Communications Commission (FCC) and the Department of Justice (DOJ) Antitrust Division after agreeing to a series of concessions designed to preserve competition in the U.S. wireless market.

A group of state attorneys general filed a multistate lawsuit seeking to block the deal. Numerous attorneys general joined that effort, only for T-Mobile and Sprint to woo them one by one with state-specific concessions in order to coax some into withdrawing from the suit. The case went to trial in December, and this week, a federal judge officially signed off on the deal that will reshape the telecom industry for years to come.

Get ready for New T-Mobile.

Marcelo Claure and John Legere next to T-Mobile and Sprint logos

Image source: T-Mobile.

T-Mobile is a "maverick"

In his 173-page decision, Judge Victor Marrero concluded that the merger "is not reasonably likely to substantially lessen competition" in the wireless market. The judge cited T-Mobile's radical Un-carrier transformation, which has yielded many tangible benefits to consumers through intense competition, and expressed confidence that T-Mobile would continue upon that competitive path.

"T-Mobile has redefined itself over the past decade as a maverick that has spurred the two largest players in its industry to make numerous pro-consumer changes," Marrero wrote. "The Proposed Merger would allow the merged company to continue T-Mobile's undeniably successful business strategy for the foreseeable future."

Meanwhile, Sprint's overall performance and financial condition has only continued to deteriorate, making it unlikely to "remain relevant as a significant competitor." It's a massive win for T-Mobile and Sprint, as the combined company will present a larger threat to AT&T (T 1.02%) and Verizon (VZ 1.17%). After factoring in the divestiture of prepaid businesses, the combined company is expected to have over 100 million wireless customers.

The states might appeal

While few doubt how effective T-Mobile's Un-carrier strategy has been, critics had worried that the merger would diminish competitive pressure by reducing the number of national carriers from four to three. Just because T-Mobile has competed aggressively in the past was no guarantee that it would continue to do so in the future.

New York Attorney General Letitia James, who was spearheading the legal challenge, was disappointed in the decision and said the states may possibly appeal.

"There is no doubt that reducing the mobile market from four to three will be bad for consumers, bad for workers, and bad for innovation, which is why the states stepped up and led this lawsuit," James said in a statement. "We disagree with this decision wholeheartedly, and will continue to fight the kind of consumer-harming megamergers our antitrust laws were designed to prevent."

Last and least

There's actually one final hurdle for the deal to clear, albeit it's much less daunting than the ones in the rearview mirror. The California Public Utilities Commission (CPUC) needs to approve the deal and could push for more concessions, The Wall Street Journal reported last month. It's extremely unlikely that CPUC would try to block the deal altogether since it has less leverage than federal regulators and courts, according to the report.

Outgoing T-Mobile CEO John Legere is naturally enthused, goading Ma Bell and Big Red while using his usual nicknames for them: "Look out Dumb and Dumber and Big Cable -- we are coming for you ... and you haven't seen anything yet!"