HARRISBURG — A five-year-old agreement between two Pittsburgh-based health care conglomerates can’t be extended through litigation past its June 30 expiration date, a Pennsylvania judge said Friday.

Commonwealth Court Judge Robert Simpson wrote that a clause in the 2014 consent decree involving UPMC and Highmark can’t be used to get around the deal’s explicit end date.

The end of the consent decree will trigger higher costs for Highmark insurance customers who use UPMC’s vast network.

Simpson wrote that “the modification provision was not intended to nullify the short, specific, unambiguous termination/expiration provision,” calling that element of the decree “a core principle of the agreement” that was expressly negotiated.

“The parties’ outward and objective manifestations of assent, including planning for a transition period and the negotiations over the expiration provision, support the interpretation that the modification provision was not intended to override the termination/expiration provision,” Simpson wrote.

State Sen. Michele Brooks, R-50, Jamestown, who helped broker an agreement between UPMC and Highmark to protect access to Mercer County UPMC-Horizon hospitals, said she was disappointed by the decision.

“While we have made some progress, it is very disappointing that bureaucrats do not understand how important in-network access to health care is to rural Pennsylvanians,” she said.

Brooks said the decision doesn’t affect the Horizon agreement and that UPMC has agreed to allow patients with Highmark insurance access to UPMC Hillman Cancer Center care at in-market rates.

Simpson was directed to consider the issue by the state Supreme Court, and it’s likely the justices will have the final say.

Highmark and the attorney general’s office have sought to extend the agreement, while UPMC has been staunchly opposed.

A UPMC spokesman said the health care giant was pleased with Simpson’s ruling.

“We look forward to continuing to fulfill our long-standing charitable mission and serving the public with UPMC’s world-class physicians and facilities,” said UPMC spokesman Paul Wood.

The case was launched in February by Democratic Attorney General Josh Shapiro, whose lawsuit sought to keep the consent decree in place indefinitely. Shapiro has accused UPMC of wasting charitable assets through “exorbitant executive salaries and perquisites in the form of corporate jets and prestigious office space waste.”

Shapiro said his office will announce his next legal steps next week.

“Make no mistake — our work here is not done,” Shapiro said. “While we are disappointed in Judge Simpson’s ruling, I won’t quit on the people of western Pennsylvania and we will continue to take steps to restore fairness to the health care system and give people access to the institutions their tax dollars built.”

Highmark spokesman Aaron Billger called the decision a temporary setback “in preserving health care choice for customers.”

“The attorney general has several options for going forward, including appealing the Commonwealth Court’s ruling to the Pennsylvania Supreme Court or returning to the Commonwealth Court to pursue the three remaining counts against UPMC in his petition, which focuses on protecting patients and health care consumers and allege that UPMC violated its nonprofit, charitable mission,” Billger said.

An agreement between Highmark and UPMC was about to expire in 2014 when they negotiated the consent decree to keep in-network rates for Highmark customers in the Pittsburgh area and Erie.

The Herald staff contributed to this story.