About 40 people slept overnight on cots at the Martha’s Vineyard Airport this weekend after a pair of late flights were canceled.

JetBlue flights to Washington D.C. and New York were grounded Saturday due to the evening storms and several other factors, stranding dozens of people who were unable to get a last-minute reservation off the busy Island, said Geoff Freeman, the airport director.

Around 11 p.m. West Tisbury police, emergency management officials and Oak Bluffs firefighters started to coordinate a shelter at the airport for between 35 to 45 tired travelers

“There were many people who were stranded,” said Russell Hartenstine, the emergency management director for West Tisbury. “We were there to help them out.”

The Oak Bluffs Fire Department brought cots to the airport from the Oak Bluffs School and they were scattered through the small terminal building.

“It was nice to provide these people a place to lay down that’s not the floor of the airport,” said Nelson Wirtz, the Oak Bluffs fire chief.

One plane ended up leaving without passengers and another had to be deboarded because the flight crews were timed out under federal regulations, according to airport commission chair Bob Rosenbaum.

Nancy Osborne was one of the stranded flyers and she spent the night at the airport with her family, including her 83-year-old mother. They were hoping to fly back to Washington, D.C. on their JetBlue flight, which was originally supposed to leave around 4 p.m. Saturday.

Some travelers were able to go back to their Vineyard homes, Ms. Osborne said, but many didn’t have the money or time to book one of the few remaining hotel rooms on a busy summer weekend.

Ms. Osborne called one hotel, where the cheapest room was $600, and another that only had a $1,200 room available.

“The people who got left there were people who had no place to go,” she said. “There were a lot of people in a much more marginal situation.”

The terminal normally closes after the last flight of the day departs, according to Mr. Freeman. This was the first time during his tenure that this many people were stranded and forced to stay overnight.

“Given the fact there were so many people, we had to keep it open,” Mr. Freeman said.

The impromptu shelter was broken down Sunday morning and folks were being rebooked on new flights.

Ms. Osborne, who has been visiting the Island for years, said she ended up taking the New Bedford ferry out of Oak Bluffs, caught an Uber to Providence, Rhode Island, and then rented a car to get back to northern Virginia.

“It’s a problem for Islands like that,” she said. “We will never fly on and off like that again.”