Virginia officials spent $500,000 in legal fees as part of Gov. Robert F. McDonnell’s effort to remove a union official from the board of the Metropolitan Washington Airports Authority.

The governor’s office disclosed the expenses Tuesday, a day after MWAA officials said they spent more than $1.5 million on legal fees to settle the dispute between McDonnell and the union official, Dennis Martire.

In June, McDonnell sought to remove Martire from the board, which is overseeing construction of the $5.6 billion Dulles Rail project. But Martire resisted and filed a lawsuit to block his ouster.

In total, the state and the MWAA spent more than $2 million on the case before it was settled in September.

Virginia Transportation Secretary Sean T. Connaughton defended the governor’s decision to remove Martire, who is vice president and Mid-Atlantic regional manager of Laborers’ International Union of North America.

Martire was faulted for running up expensive bills while traveling on business for the MWAA, which at the time lacked specific rules governing such expenses.

“Ample cause existed for Mr. Martire’s removal,” Connaughton said in an e-mailed statement. “The Commonwealth regarded his attempted avoidance of the governor’s removal action and his use of the litigation process to involve other MWAA Board members as frivolous.”

Connaughton said the state paid the law firm Thompson Coburn $500,000 for work on the case. He said the governor chose to have the matter handled by outside counsel because of the “complexity of the litigation.”

Martire, who was appointed to the board by McDonnell’s Democratic predecessor, Timothy M. Kaine, had clashed with the current governor on a range of issues, including the inclusion of a labor-friendly provision in the second phase of the Dulles Rail project. After months of legal wrangling, the parties settled the dispute in September. Terms of the settlement were not made public. The governor’s office rejected a public-records request by The Washington Post for a copy of the settlement, citing an exemption under the law for “correspondence of the governor.”

After vowing to fight his ouster, Martire said he ultimately decided to settle his case in part because he — and the authority — were concerned about the cost of litigation.

Under the MWAA’s bylaws, the authority was obligated to pay for Martire’s legal expenses in the dispute. But three of Martire’s board colleagues — former Virginia congressman Tom Davis, Rusty Conner and Todd Stottlemyer — questioned whether the MWAA should be responsible for Martire’s legal bills.

The $855,000 that the MWAA spent on Martire’s case went to Williams & Connolly, which represented Martire. The authority also paid $360,000 to Hunton & Williams for representing the authority in the litigation. According to invoices, Hunton & Williams’s fees ranged from $675 to $175 an hour.

Records show that the MWAA also paid $195,000 in legal fees to DLA Piper for Davis, Conner and Stottlemyer after they became caught up in the litigation. Conner, a partner at DLA Piper, said in an interview he did not think there was a conflict of interest in having his own firm represent the three board members.

The authority also paid $102,000 to the firm of Troutman Sanders, which represented Caren Merrick, who was named by the governor to replace Martire on the board.

It is possible that Martire’s actual fees were higher, but as part of the settlement, the authority and Martire’s attorneys agreed to have a third party determine “reasonable” fees.

MWAA officials have said they will reexamine its indemnity clause. In addition to overseeing the Dulles Rail project, the MWAA manages Washington Dulles International and Reagan National airports as well as the Dulles Toll Road.