Seemingly sane BRITNEY SPEARS is biting her nails down “to the nub” which is oh-so-visible to eagle eyed X-FACTOR viewers.

 And now “The X Factor” team is  trying to make BRITNEY SPEARS an X nail-biter!

 In an effort to get the 31-year-old pop star to stop gnawing on her finger­nails – a habit she’s had for years – the makeup artists at the popular FOX reality show have been applying bitter-tasting polish to Britney’s severely damaged digits.

“Britney’s nails are almost nonexistent,” an insider on the show told The ENQUIRER. “She’s bitten them down so low that she’s drawn blood. There’s hardly anything left to even glue a fake nail onto.

“The crew has tried EVERYTHING, includ­ing a product that moms put on toddlers fingers to keep them from sucking on their thumbs. But it didn’t work. That’s when the makeup department got creative and started using a bitter-tasting nail polish.

“So far, that seems to be doing the trick.”

According to sources, Britney’s nail-biting habit goes into overdrive when she gets anxious or stressed out. And, as we reported in our Nov. 5 issue, the “Toxic” singer suffered an emotional meltdown recently after learning that her former boyfriend Justin Timberlake had tied the knot with Jessica Biel.

“Justin’s wedding was definitely a ‘nail relapse,’ ” the source revealed.

While the nail polish has curbed the habit for now, those who know Britney have little hope it will be a permanent solution.

Simon Cowell joked that Britney will probably get used to the taste,” added the source. “Then she’ll go right back to biting her nails to the nub.”