July 30, 2021 | 4:33pm

Erika Jayne’s diamond is cracking — and it may be used against her.

Statements that the “Real Housewives of Beverly Hills” star, 50, made on the show could be brought up in court by Ronald Richards, the attorney investigating the bankruptcy case of Girardi Keese, her estranged husband Tom Girardi’s law firm.

“The show is a treasure trove of self-authenticating admissions from non-scripted actors who did not anticipate that many months later those statements would come back to haunt them or that they would be investigated,” Richards told Page Six in a statement on Friday.

“This is because none of the housewives have a duty to tell the truth on television. They are now caught in [an] undesirable legal position, were they lying then or now.”

He explained to US Weekly that his team is working on taking “discovery from people that used to work for her” to decipher some of her comments.

“There’s a lot of inconsistent statements and admissions made by the non-scripted actors that we’re putting together to use in court,” Richards told the outlet.

Richards said that there is no set date for when this could happen.

“There’s a lot of things we’re still trying to uncover,” Richards affirmed. “We are going to be deposed at some point but I want to get all the documents first. What’s important right now is following the money.”

For her part, Jayne has asked the court to remove Richards from the case, claiming he made “false and inflammatory social media posts and public statements” suggesting that she was not participating in his investigation.

She also slammed him as a “clown ass,” “low budget” lawyer on Twitter.