Maine will receive $28 million in federal funds for the Downeaster rail service, most of which will go toward improving the track that connects Brunswick to Boston.

Of the $28 million, $27.5 million will pay for “track-related improvements” to help with safety, performance and competitiveness, according to U.S. Rep. Chellie Pingree (D-1st District).

The other $500,000 will go toward the Downeaster Corridor project, which proposes improvements in southwestern coastal Maine, southeastern New Hampshire and an extension east to Rockland.

The proposal calls for more frequent trips, faster travel, improved reliability and a new station in West Falmouth, according to Pingree’s office.

The funds are part of $8.2 billion in new funding for 10 major passenger rail projects across the country.

In a statement, Pingree said the funds are part of the Bipartisan Infrastructure Law and will improve rail service while fighting climate change.

“The Downeaster is one of the best performing regional Amtrak passenger rails in the country — with over a half of a million people choosing to ride the train in the last year alone,” Pingree said. “The significant investments announced today will greatly improve the highly traveled Boston to Brunswick line, ensuring safe and climate-friendly travel options, creating jobs, and boosting economic activity in surrounding communities.”