Reps for the Beach Boys are threatening to sue Katy Perry after she included their classic line “I wish they all could be California Girls,” in her song “California Gurls.”

Rondor Music has fired off a letter to Perry’s label, Capitol Records, demanding Mike Love and Brian Wilson — who penned the 1965 classic “California Girls” — be given a writing credit on Perry’s hit summer song, as well as royalties.

A record industry source told Page Six, “Rondor Music has sent a letter to Capitol on behalf of Mike Love and Brian Wilson, saying Katy has cribbed one of the most famous lyrics in history, so Love and Wilson should be entitled to a writing credit and a portion of the royalties.”

The legendary line is uttered by Snoop Dogg at the very end of Perry’s track, which has sold more than 3 million copies, making it the anthem of the summer.

Although sources told us that Wilson and Love asked Rondor to take action, reps for both musicians claimed it was Rondor’s idea. Wilson’s rep said, “Rondor owns the track and called Brian and Mike, saying they were going to complain. Brian likes Katy’s record and doesn’t know where the situation stands.” Love’s rep said, “Mike and Brian wrote the song . . . but any legal action is up to Rondor.”

Both Beach Boys had previously said they were flattered after Perry said her song was written as a tribute to the group. Love told Billboard, “The subject matter is still in vogue — just ask Katy Perry. I think the part she did is pretty cool. There are a lot of writers on it, and I think it’s probably a stroke of genius to have the king of canine cool, Mr. [Snoop] Dogg, do his thing. But I think her creative part, her musical part, is pretty hooky. I think it brings the Beach Boys’ 1965 classic to mind, that’s for sure.”

And Wilson told the LA Times, “I love her vocal. She sounds very clear and energetic . . . The melody is infectious.”

A rep for Perry and Capitol didn’t get back to us. Rondor declined to comment.