Aetna Inc., a major health insurer in the Philadelphia region, has agreed to pay $5.7 billion to buy competitor Coventry Healthcare Inc. in a bid to expand its Medicaid business and other operations before major provisions of the Affordable Care Act take effect, the companies said Monday.

In 2014, many states are expected to expand Medicaid to cover a significant portion of the currently uninsured, increasing business opportunities for companies that run those programs for states.

That year is also when state-run insurance exchanges will start operating, allowing individuals and small businesses to purchase health coverage in what is supposed to be a more understandable and competitive forum.

"As we think about 2014 and beyond, Coventry's intense local focus with substantial small-group and individual membership, a low-cost operating model, and affordable products will complement Aetna's [strengths and] accelerate our readiness for the consumer exchanges," Mark T. Bertolini, Aetna's chairman and chief executive, said on a conference call.

"With respect to Medicaid, Aetna's footprint will now cover 14 states, where over one-third of all Medicaid and dual-eligible members reside," Bertolini said.

The deal, which both boards of directors have approved but which still requires Coventry shareholder approval, will double Aetna's Medicaid revenue and triple its Medicaid membership, according to Aetna, which is based in Hartford, Conn. Coventry is based in Bethesda, Md.

Aetna highlighted the fact that the purchase of Coventry will boost its share of revenue from government programs from 23 percent to 31 percent, a sign of its confidence that government-sponsored insurance will remain important to the health-care system despite persistent budget turmoil.

Aetna is the second-biggest health insurer in the five-county Southeastern Pennsylvania region, behind Independence Blue Cross. It has roughly 3,000 employees in the region.

But it has "a weak presence in the central [Pennsylvania] area, which happens to be where Coventry-Health America is strongest," said Scott Crane, director of employee-benefit services at Tycor Benefit Administrators Inc. in Berwyn.

Coventry, which employs 2,900 in Pennsylvania, including 120 in King of Prussia and Plymouth Meeting, entered the Pennsylvania market in 1988, when it purchased HealthAmerica Pennsylvania.

Pennsylvania is one of two states that rank in the top 10 for both Aetna and Coventry; the other is Florida.

Crane said the deal would create a company with the largest footprint in Pennsylvania, further reducing competition in a state that already does not have a lot of it.

Aetna, which also is assuming $1.6 billion of Coventry debt, said it expected to complete the purchase in the middle of next year, in time to complete the integration and be ready for the kick-off of the 2014 health-care reforms.

In similar recent deals, Cigna Corp. bought Healthspring Inc. for $3.8 billion in January, and Wellpoint Inc. agreed to pay $4.5 billion for Amerigroup Inc.

Aetna's shares rose $2.14 Monday, or 5.63 percent, to close at $40.18. Coventry's shares soared $7.10, or 20.23 percent, to close at $42.04. The cash-and-stock deal valued Coventry at about $42 per share. Both companies trade on the New York Stock Exchange.