The family of one of the teens swept out to sea at Rockaway Beach says the missing boy went in to save his friend, who couldn’t swim.

“I guess he saw his friend in trouble and went to save him,” said Ty Thompson, the cousin of 16-year-old Gabriel Rice — one of two teenage boys who went missing at the Queens oceanfront Tuesday.

The boys were unaccounted for after wading into the water near Beach 96th Street and Shore Front Parkway in Queens around 3:30 p.m, police said.

“They were playing and the waves took them. It was only up to their waist, and the waves took him out,” the distraught Thompson told The Post on the boardwalk close to where the boys went missing. “I just saw him yesterday at home…he said he was not going to go in the water.”

Rice — who knew how to swim and had been to Rockaway Beach before — was swept out to sea trying to save his drowning friend, his cousin said.

“He went to save the kid he drowned with. He’s a really good kid,” said Thompson, who said Rice was a high school junior and “so smart.”

“It’s bad, he’s my favorite little cousin. I can’t stop crying,” she added.

Thompson told The Post that police told her they don’t expect to find the boys alive.

“They say it’s a recovery now, it’s no longer a rescue,” she said.

A third teen in the group, 15, was pulled out of the rough waters by a nearby surfer shortly after the boys went missing, officials said.

Rockaways Park Administrator Eric Peterson said the yearly number of beach drowning deaths was higher than usual.

“There were six this year,” he said. “These are all very tragic. Even one is more than we want to see,” he said.

The beaches have been closed to swimmers since Sept. 8 — though Mayor Bill de Blasio on Wednesday ordered additional patrols, including FDNY members “trained to make cold water rescues,” as temperatures were expected to hit an unseasonably high 91 degrees.