Source: Coca-Cola website

It seems that soda's best days might be in the past. After several decades of rising popularity, which helped The Coca-Cola Company (NYSE:KO) and PepsiCo (NASDAQ:PEP) richly reward their shareholders, soda is losing favor. In fact, Beverage Digest reports that U.S. soda sales fell nearly 1% in 2014, representing the 10th consecutive year of declining sales.

Clearly, this is a problem the industry is struggling to overcome. It seems consumers are shying away from high-calorie, sugary beverages in favor of healthier drinks. With that in mind, here is how the two biggest soda companies, Coca-Cola and PepsiCo, are adapting to the changing times and why their stocks remain ones to watch.

For both companies, the name of the game is new products. Coca-Cola holds one of the strongest brands in the world, and its flagship Coke remains the most popular soda in the U.S. by a considerable margin. Beverage Digest noted Coke still retains 42% market share. But growth is slowing, with Coke's volume down by 1.1% last year. The company's revenue grew only 1% last quarter, although organic revenue, which strips out the effects of currency translations, rose 8% year over year.

Coca-Cola is at a turning point. Management has referred to 2015 as a transition year. The company is investing in building out its market share in new categories, and it will take time for its strategic initiatives to gain traction. But Coca-Cola is seeing some near-term success.

The company's new products are centered on juices and teas. Last year, three of the company's brands in these categories, Gold Peak tea, FUZE TEA, and I LOHAS mineral water, each eclipsed $1 billion in retail sales.Gold Peak is a premium tea brand that Coca-Cola unveiled in 2006. FUZE TEA is sold in nearly 40 countries across the world. I LOHAS was launched in 2009, and has since become the top-selling mineral water brand in Japan.

PepsiCo got a bit of good news in the Beverage Digest report, as its core Pepsi soda overtook Diet Coke to become the No. 2 brand in the United States. Pepsi holds 27% market share, but it is also in decline. Pepsi volume fell 1.4% last year, and 1% in the first quarter, although PepsiCo did offset this somewhat with 3% higher pricing.

PepsiCo, a snacks powerhouse in addition to beverages, is building out its brands across several categories. The company separates its products into three different groups: Good For You, Better For You, and Fun For You. Among the Good For You category are many of the company's higher-growth brands, including Sabra hummus.

Like Coca-Cola, PepsiCo is building out its beverage portfolio, with brands including Naked juice and Aquafina water. But PepsiCo is counting even more on its food business to fuel future growth and diversify it away from sparkling beverages. Its Frito-Lay division holds a number of snacks brands, including Doritos, Ruffles, and Tostitos. PepsiCo also operates the Quaker brand. In all, PepsiCo's total revenue is about evenly split between food and beverages. This has helped PepsiCo greatly. For example, the food business generated 18% organic revenue growth in Latin America last quarter.

Watch these two soda stocks
Coca-Cola and PepsiCo dominate the soda industry and they aren't standing still. To counter sluggish soda sales growth, both companies are investing aggressively in brands that are more responsive to changing consumer tastes.

Coca-Cola and PepsiCo have long track records of rewarding shareholders with profits and dividend payments -- KO currently yields 3.2% and PEP yields 2.9% -- and they hope that investments in healthier products will sustain their success for many decades to come.