Latin American airline stocks had a rough time in 2014 and 2015. Economic weakness in the region and a rising dollar more than offset the benefit from lower oil prices.

However, shares of LATAM Airlines (NYSE:LFL) and Copa Holdings (NYSE:CPA) -- two of the most important airlines in the region -- came roaring back last year. LATAM stock jumped 52% and Copa stock surged 88% in 2016, according to data from S&P Global Market Intelligence.

LFL Chart

LATAM Airlines vs. Copa Holdings Stock Performance data by YCharts.

Even after posting those strong gains, shares of LATAM and Copa remain well below their 2014 levels. However, they may struggle to continue rising in 2017.

Signs of stabilization

Both LATAM and Copa have shown signs of getting back on track over the past year. They started by pulling back on their capacity growth in the face of weakening demand.

Copa increased its capacity just 1.5% last year, compared to 4.4% growth in 2015. This helped it increase its load factor (the percentage of seats filled by paying customers) by more than 5 percentage points. Meanwhile, LATAM increased its capacity just 0.6% in 2016. In Brazil specifically, LATAM slashed its capacity by double digits.

This capacity rationalization has led to better margin results. As of last November, LATAM expected to deliver a full-year 2016 operating margin of 5.5% to 6.5%, up from 5.1% in 2015. Around the same time, Copa forecast that its operating margin would rise from 11.8% in 2015 to a range of 12% to 13% in 2016.

Both companies expect their results to strengthen further in 2017. Copa's preliminary outlook calls for a 15% to 17% operating margin this year, while LATAM expects its operating margin to reach 6% to 8%. However, they could soon be facing new headwinds.

A strong dollar is a big risk

The rising dollar contributed to earnings pressure at LATAM and Copa in 2015 and early 2016. Oil, airplanes, and spare parts are all priced in dollars, and a strong dollar drives up those costs in local-currency terms for airlines outside the U.S.

LATAM has been particularly hard hit, because Brazil is its largest market and the Brazilian real fared poorly against the dollar in 2015, before recovering in 2016.

LATAM Airlines plane

The strong dollar hurt LATAM's profit margin in 2014 and 2015. Image source: Airbus/LATAM Airlines.

Copa is based in Panama, which uses the dollar as its functional currency. However, it still isn't immune to currency swings. Copa operates a hub and spoke business model, drawing customers from across Latin America (and the U.S. and Canada, to a lesser extent) and connecting them to other destinations in the region. As a result, it also suffers when the dollar is strengthening.

The dollar rose sharply again in the last few months of 2016, although it has pulled back in the past month. A controversial "border tax" plan in the U.S. could potentially drive the dollar even higher in the next few years. This represents a key risk for both LATAM and Copa.

More competition is coming

Rising low-cost competition in Central America and South America represents an even bigger long-term risk for LATAM and Copa. Today, the region lacks any major ultra-low cost carriers (ULCCs) -- the no-frills airlines that have helped tame pricing across Europe, Asia, and North America.

That could be about to change. Volaris (NYSE:VLRS), the largest ULCC in Mexico, recently set up a new affiliate based in Costa Rica to serve routes within Central America. Volaris has rock-bottom costs. It can make a healthy profit at fare levels where very few other airlines would break even.

Volaris' proven ability to offer cheap point-to-point service -- even in relatively small markets -- could put pressure on fares in some of Copa's key markets. Volaris ultimately hopes to deploy 18 to 22 aircraft in Central America, though it will take several years for operations to ramp up.

Looking further south, the "Viva" ULCC brand is looking to expand in the near future. Ryanair co-founder Declan Ryan is looking to sell his 49% stake in VivaAerobus -- Mexico's other major budget airline -- and use the proceeds to build up ULCCs in other markets within Latin America.

Ryan plans to begin with Colombia and Argentina, but he has also mentioned Venezuela, Costa Rica, and Panama as long-term opportunities. A broad expansion like this could hurt incumbent carriers like Copa and LATAM.

In response, Copa and LATAM are working hard to cut costs. They are also experimenting with new, lower-frills business models. It's a good sign that both companies are being proactive. Nevertheless, the potential combination of a rising dollar and new competition could limit their profit growth in the years ahead.