Nearly one in three teens and young adults have shared or viewed sexually explicit photos and messages via cellphones or online, according to a new survey.

Despite clampdowns by law enforcement in a handful of states and at least two suicides of girls whose nude photos had been passed around at school, city teens said the practice — known as “sexting” — showed no signs of abating.

“You’d be surprised how often it happens — everyone sends racy messages to each other,” said Rashawn Preston, an 18-year-old senior at Martin Luther King HS on the Upper West Side who estimated that he gets “sexts” from about three girls a week.

“A girl likes you and she will sext you to get your attention. You can’t see each other, so she’ll send you pictures of herself, her body,” he added. “It’s very out there, and people don’t care.”

The MTV-Associated Press poll of more than 1,200 14- to 24-year-olds found that 18 percent of them had been sent naked photos or videos that a person took of themselves, while 10 percent had sent images of their own nude bodies to others electronically.

Additionally, 8 percent said they had received naked images of someone other than the sender — supporting fears that intimate exchanges aren’t subject to privacy.

“You hear a lot about a guy and girl sexting, and then the guy doesn’t want to talk to her anymore, so he shows the messages to everyone,” said Jenan Elcheikhali, a 17-year-old senior at La Guardia HS on the Upper West Side.

“It’s irresponsible, because once you send it, you can never take it back, and who knows what will happen to the message once it’s out there.”

Even though more than half the teens surveyed recognized that sharing naked images electronically was “dangerous,” it didn’t seem to curb their habits much.

The city public-school system’s sex-education curriculum — which is recommended but not mandated — does not include a sexting component, school officials said.

The poll was part of MTV’s “A Thin Line” campaign to stop the spread of digital abuse.