how long have you had him? how long is his full tail+body length? what kind of substrate and home do you have him in? is it sudden weight loss and lack of eating, or slowly going downhill? what are you offering him to eat? does he have energy, or just lie there?

if you haven’t had him more than a couple months and hes loosing weight he could have some type of internal parasite that’s wearing him out. he might have a really bad infection somewhere in his body that is tiring him out and making him lethargic
( one of my yearlings had an infection in his cheek that by the time i noticed it, it was pushing on his eye. i drained it multiple times and put saline solution on it and it mostly healed, but the infection had migrated to other parts of his body and after a couple months of treatment and force feeding, he finally died painfully with liquid in his lungs in my hand.) 2 of my others used to get buildups of plaque-like material in their cheeks that id occasionally have to clean out, saline cleared them.
id suggest that you try force feeding him mushed up horn worm or some other tasty bug treat, you might have to use a baby syringe.

my mommy lizard will only eat live crickets, locusts and grasshoppers. a couple of her sons will also eat wood bugs, and one will eat small worms. allies can be very picky.

mine only partly burmated, but they didn’t fully, i kept their lamps on for about the same length as i do during the summer. if his body is thinner than his head and you can lightly feel/see his hip bones, then he is very very underweight. when did he last eat? a few days or a week isn’t to worry. ( my mommy got badly beat up by her hormonal sons, she stopped eating for a couple weeks, but lots of hydrogen-peroxide and polysporn treatments later, and some force feeding, shes feeling all better now.)

i hope some of this helps. if you have any veterinarians nearby that deal with reptiles(phone first, cuz lots don’t know what to do). you can bring him into your local petsmart or other pet store that sells reptiles and have someone take a look at him for free, i did this and it might help you, but all they suggested to me was force feeding and the saline. they might have some kind of weak antibiotic either their or the vet, but their isn’t much known about reptile prescribed drugs and medicine.