Starbucks, which doles out more than 1 billion straws a year, says it will phase out single-use plastic straws from its stores by 2020.

The coffee giant said Monday that it will replace the ubiquitous plastic straw with recyclable “strawless lids,” as well as straws made from biodegradable materials, as part of a no-plastic-straws movement that has gained momentum in recent years.

Starbucks — which has more than 28,000 stores and generated $22.4 billion in annual revenue last year — is the largest retailer to commit to eliminating single-use plastic straws. The company said that more than half of its beverage sales come from cold drinks, which typically come with a plastic straw.

The no-straw movement, which had already been brewing in certain communities and beach towns, gained mainstream traction three years ago after a video showing a sea turtle with a plastic straw wedged in its nose went viral. Plastic straws never completely decompose and can be harmful, even fatal, to animals that ingest them.

A number of local governments have recently passed legislation restricting the use and distribution of plastic straws. Starbucks’s hometown of Seattle, for example, banned plastic straws and utensils beginning this month, while the California cities of Davis and San Luis Obispo prohibit restaurants from handing out plastic straws unless a customer requests one.

A number of restaurants and private establishments also have taken measures to curb their use of plastic straws. Some offer more environmentally friendly alternatives, such as straws made of paper, bamboo, steel, even Twizzlers. Walt Disney World has banned plastic straws at some of its theme parks, while the Smithsonian Institution has taken steps to eliminate them from its museums.

At Starbucks, executives said the efforts are part of a $10 million plan to develop cups and lids that are fully recyclable and compostable. Stores in Seattle and Vancouver will be the first to begin using the new strawless lids, which will be used for iced coffee, tea and espresso drinks beginning in the fall. Ice-blended Frappuccinos, meanwhile, will be served with straws made of paper or compostable plastic.

The company also offers a 10-cent discount to customers who bring in their own cups.

“This is a significant milestone to achieve our global aspiration of sustainable coffee, served to our customers in more sustainable ways,” Kevin Johnson, president and chief executive of Starbucks, said in a statement.