AFTER shedding almost an alarming 40 pounds for a movie role, MATTHEW McCONAUGHEY fears he’s damaged his body permanently, pals say.

The 43-year-old actor whittled down his once-buff physique for his dramatic role as an HIV-infected man in “Dallas Buyers Club.” While he’s gained back most of the weight, sources say he’s still not feeling top-notch.

“Matt dropped from 180 pounds to 147 in just a few months, but losing all that weight really took a toll on him,” said a friend.

“While he’s regained much of the muscle he lost, Matt’s endurance is nowhere near what it once was.

“It’s a concern for him – a big one. He doesn’t feel like himself.”

The ill effects of Mac’s physical transformation really affected him when he started filming his upcoming HBO series “True Detective,” said the source.

“Matt barely made it to noon on the set and he was just beat,” revealed the source. “He’s gone to doctors and consulted nutritionists to try to get his endurance back, but he hasn’t seemed to get over the hump.”

Although the actor’s rep denies he’s suffering from any weight-related health problems, a source says that his physical condition has set off alarm bells for wife Camila Alves, 30, who’s the mother of his children Levi, 5, Vida, 3, and Livingston, 10 months.

“At first, Camila was very supportive because she knows how much being taken seriously as an actor means to Matt,” a friend said. “She even fixed low-calorie meals to help him lose weight.

“But now, with Matt being tired and having trouble sleeping soundly, she’s afraid he did permanent damage to his heart and his lungs. Camila made Matt promise that he’d never do this to his body again. She’s doesn’t want to be a widow with young children.”

But an expert says Camila may be worrying needlessly.

“Crash dieting or rapid weight loss can re­sult in long-term damage of the organs which could cause his fatigue,” Dr. Richard Shames, co-author of “Thyroid Mind Power” and an expert in body metabolism, who hasn’t treated McConaughey, told The ENQUIRER.

“But most likely his condition is benign and can be reversed.”

DOSES OF VITAMIN B5 AND D, along with a diet rich in fruits and vegetables, would most likely boost his fitness level, Dr. Shames added.

Meanwhile, McConaughey – most famous as a romantic leading man before his roles in “Mud” and “The Lincoln Lawyer” – hopes his physi­cal transformation pays off with his first Oscar nomi­nation for “Dallas Buyers Club,” said the source.

“Matt was stung for years when people thought of him as a light­weight ‘himbo’ actor,” the friend explained.

“But the way he’s feel­ing now, I’m not sure he would have put his body through this.”