NEW YORK — On a recent morning, Delta Air Lines Flight 435 pushed back early from the gate at New York’s John F. Kennedy International Airport. Passengers watched the safety video and settled in for a six-hour trip.

Then they waited. And waited.

Still within sight of the gate, their jet sat motionless due to airport congestion. It wasn’t until 30 minutes after passengers buckled in that they were finally in the sky.

It’s a scene playing out across the country. According to an Associated Press analysis, airplanes spent 23 minutes and 32 seconds, on average, taxiing between gates and runways during the first nine months of the year. That’s the longest it has been since the Bureau of Transportation Statistics started tracking taxi times in 1995 and a 50-second increase over last year’s average.

For passengers, the rising delays add to the frustrations of travel. A plane might land early but then sit waiting for a gate to open up. Flights are still arriving “on time” but only because airlines have increased scheduled flying times to account for the added taxi times. The Delta flight made it to the gate in San Francisco 10 minutes ahead of schedule despite the takeoff delays.

The creep in taxi times is attributed to a series of changes: massive runway construction projects at some of the nation’s busiest airports; schedule changes that increase the number of flights at peak hours; and new, distant runways that relieve congestion but require more time to reach.

“It’s death by a thousand cuts,” says Vikram Krishnan, a partner in the aviation practice of consultancy Oliver Wyman.

The problems on the ground are costing airlines dearly.

“Two, three, four, five minutes in a fleet of 500 planes a day is significant amounts of money,” says aviation consultant Mike Boyd.

That translates into hundreds of millions of dollars extra in operating costs so far this year, according to AP calculations factoring in average operating costs including pilot and flight attendant salaries.

Airlines say the longer taxi times are baked into schedules, so planes generally still arrive on time. So far this year, 79 percent of flights have been at the gate within 15 minutes of their scheduled time, the best performance since 2012.

Passengers might be spending more time on planes, but airlines are better managing their expectations by increasing scheduled times. That masks some of the problems, like taxi delays.

For instance, 10 years ago the average scheduled time from gate to gate between Chicago and San Francisco was 4 hours and 32 minutes. Today, flights are scheduled for an extra 11 minutes, according to PlaneStats.com — even though airports in the two cities are the same 1,846 miles apart.

All it takes are a few problems at some of the country’s busiest airports to drive up the national taxi time average.

The top offender in the past year was Chicago’s O’Hare International Airport. Of all the additional taxi time minutes in the nation, one of out of five extra minutes can be traced back to delays at O’Hare.

Most of the problems at O’Hare stem from a construction project that is reconfiguring taxiways and runways. The long-term goal is to reduce congestion but delays racked up during the construction. A new runway did just open, but farther away from the terminals.