When Mesa Airlines stepped up to the bargaining table, American Airlines thought it had won.

According to a Friday union announcement, Mesa Airlines pilots will soon go from being some of the worst-paid pilots to having the highest wages in the industry. Mesa flies partner planes called American Eagle, United Express, and DHL.

First-year captains will be paid $150 an hour, while entry-level first officers will be paid $100 an hour. According to The Points Guy, Mesa pilots will get a significant pay increase.

Captains with 20 years of experience will be paid $215 an hour.

The announcement comes as labor shortages plague the aviation industry and lead to a summer filled with flight delays and canceled flights.

There is a lack of trained pilots at the regional level. Smaller carriers like Mesa have struggled to retain talent this year as mainline operators like American have more competitive pay.

Mesa Airlines CEO Jonathan Ornstein said at a Senate Commerce aviation subcommittee hearing that the pilot shortage was the greatest threat to the industry.

Major airlines and operators of larger jets hired Mesa Airlines' pilots.

American Airlines raised pilot wages in June. First officers are paid $90 an hour and first-year captains are paid $146 an hour under the new contract.

"With strong competition in the regional industry, today's LOA offers the compensation Mesa needs to remain competitive and attract and retain experienced, qualified pilots," Capt. Chris Gill said in a press release Friday. Mesa pilots are appreciated by management and partners.