Okay, so you have a T5 UVB tube that is a good tube, but how many inches away from him is it mounted? It must be within at least 10-11" to deliver effective
UVB light to him (that goes for all T5 UVB tubes under 30 watts).
I'm going to say that his Basking Spot Surface Temperature is too low, you absolutely cannot "Assume" what his temperatures are, not any of them, but especially not his Basking Spot Surface Temperature, as this is the temperature zone that determines whether or not he can properly digest his food! And I'm going to assume that your answer means that you only have a stick-on thermometer(s), and have no way of measuring his Basking Spot Surface Temperature. This is a HUGE problem when owning a Bearded Dragon, or ANY Desert Reptile! Desert Reptiles lives literally depend upon them getting correct lighting and living within a temperature gradient that is representative of their natural environment.
The other issue with any and all stick-on thermometers is that they are extremely inaccurate, most of the round, gauge ones that are sold as being for reptiles are off by between 10-20 degrees in either direction when they are tested by an Infrared Thermometer. So you really need to at least run to the pet shop and spend $10 on a Digital Thermometer that has a Probe on a Wire. All Petco and PetSmart stores sell them, Zoo Med makes one that is yellow, and then I know at any Petco store, if they are out of the yellow ZooMed ones that are in with the reptile supplies, they also sell an identical Digital Probe Thermometer back in the Fish Aquarium section, in the aisle where the air pumps, bubble stones and wands, etc. are. It's black and I believe is the Petco brand. Both of these Digital Probe Thermometers cost $9.99 and are not optional when owning a Desert Reptile at all.
Your Hot Side Ambient/Air Temperature of 95 degrees is a bit high, assuming that the stick-on thermometer you are using is anywhere close to being accurate, so I'd be worried that his Basking Spot Surface Temperature is too hot. At a year and a half old, they typically like their Basking Spot Surface Temperature around 105 degrees, no higher. So please pick-up a $10 Probe Thermometer, and use it to measure ALL 3 TEMPERATURE ZONES, as if they are too hot this will definitely slow his appetite and cause lethargy. BE SURE TO ALLOW THE PROBE TO SIT IN THE SPOT YOU ARE MEASURING FOR AT LEAST 20-30 MINUTES EACH TIME BEFORE YOU READ THE TEMPERATURE, OTHERWISE IT WILL NOT BE ACCURATE, YOU HAVE TO ENSURE THAT THE TEMPERATURE ON THE THERMOMETER IS NO LONGER RISING. Obviously you can put the probe directly on his Basking Spot/Platform on the exact spot that he sits to bask, wait 30 minutes, then read the temperature. As far as using a Probe to measure his Hot and Cool Side Ambient/Air Temperatures, use the Suction Cup that comes with the Probe Thermometer and place it on the wire right below the Probe. Then stick the Suction Cup to the glass of the tank on the Hot Side, either the front glass or the side glass, about 2" above the floor of the tank, wait 30 minutes, then read the temperature. Then do the same on the Cool Side.
********As far as using grass/alfalfa pellets as the substrate for a Bearded Dragon, there are a dozen reasons why this is an awful choice as his substrate, but the best reason that I can give you that should make total sense to you, is THEY DON'T LIVE ON PELLETS IN THEIR NATURAL ENVIRONMENT. Obviously when you decide to bring a reptile, amphibian, etc. into your home and your life, your main goal when you're setting-up their enclosure/tank SHOULD BE to replicate their natural environment as closely as you possibly can. Why? Well, while most people will immediately say because it's what they are going to innately recognize and feel comfortable living in, which is very true. However, what most people don't think of or realize is that each different species' bodies are quite literally built/designed to not only live/survive in that natural environment, but also to THRIVE in that particular environment. That's why your Dragon getting at least 13-14 hours of strong, adequate wavelength UVB/UVA light every single day is not optional, because his body absolutely needs that to thrive and survive (KNOBBY'S WAS CORRECT, 10 HOURS IS FAR TOO SHORT A DAILY PHOTOPERIOD, PLEASE LEAVE BOTH HIS UVB TUBE AND HIS BRIGHT-WHITE COLORED BASKING BULB ON EVERY DAY FOR AT LEAST 13-14 HOURS MINIMUM)...
Bearded Dragons come naturally from the Deserts of Australia ONLY. No where else in the world. And if you've ever seen photos of the Australian Deserts that they naturally live in, there is little to no sand at all (so many people, especially from the US, automatically think that Dragons live in Deserts that are nothing but endless miles of deep sand, like the Deserts in California, Arizona, Nevada, New Mexico, etc.) The Deserts in Australia that they come from are a very hard, rocky terrain with different types of vegetation throughout, but little to no sand. The only "loose" matter on the ground are rocks/stones.
Forgetting that Bearded Dragons lick EVERYTHING as a type of sense, so yes, they are going to eat/swallow any and all types of loose substrate that you put them on, that's not always the main issue with certain loose substrates, like alfalfa/grass pellets. In my opinion, the main issue with Bearded Dragons living on ANY loose substrate at all is their propensity for #1) Skin/Scale Infections (bacterial, fungal, and parasitic), #2) Upper Respiratory Infections (this is a huge issue caused by loose substrates), #3) Chronic Eye infections and Irritations, and #4) The possibility of "Tail Rot" developing from an open wound/injury on their tails....ALL loose substrates are perfect breeding grounds for all harmful, infection-causing microbes, including bacteria, fungi, parasites, etc. The chance of them developing an Upper Respiratory Infection from not only the microbes that are harbored by all loose substrates, but simply from breathing in the DUST and small particles created by all loose substrates is extremely great. You've got to realize that your Dragon is sitting/laying on and walking in/through those pellets all day and all night, and he's constantly breathing-in the dust and small particles that are all throughout the tank. His chance of developing an Upper Respiratory Infection is huge, and not only that, but ALL ALFALFA/GRASS PELLETS CAN CONTAIN VERY HARMFUL FUNGAL SPORES THAT CAN CAUSE AN ASPERGILLUS INFECTION IN THEIR LUNGS, which is usually fatal, even with treatment by an experienced Reptile Vet with the correct Anti-Fungal medications.
So the question becomes, or already is, "Why in the world would you want to keep your Bearded Dragon on a loose substrate that is not only completely unnatural to him, but that is also potentially very harmful to his health?" And in the case of these pellets, I'm sorry, I don't understand using them in the first place at all...I'm not trying to be rude or disrespectful in any way, but as Knobbys already said, Alfalfa/Grass pellets might be great for rabbits, guinea pigs, hamsters, ferrets, or other rodents and small animals, but why in the world would anyone think to use them as the substrate for a Lizard that comes from the Australian Deserts? I just don't get that one, it would never occur to me to even consider using grass/alfalfa pellets as a substrate for any reptile/amphibian...Anyway, please do the right thing for your Dragon and dump the pellets out immediately, and then completely disinfect the entire inside of his tank and all of the decor as well, with very hot water and either F10 Disinfectant, Bleach, or Vinegar...You can also completely disinfect any decor made of stone, wood, or ceramics by pre-heating your oven to 250 degrees, and then placing them all directly on the oven rack and baking them for 45 minutes, then turn the oven off and let them sit for another hour or so, as they will be extremely hot. This method safely kills all of the harmful microbes that are living deep inside the porous wood and rocks.
*******As far as why your Dragon has stopped eating, I highly suggest that you go and pick-up a Digital Probe Thermometer and then properly take all 3 temperatures inside his tank, and I think that you'll find his temps are too hot, and this is influencing his appetite. Also, once again, make sure that the T5 UVB tube is within at least 10-11" of your Dragon's Basking Spot/Platform, and also please extend his daily Photoperiod of both his UVB tube and his bright-white colored Basking Bulb from 10 hours a day to at least 13-14 hours a day, as 10 is far too short. Assuming his temperature zones are too hot, you can adjust this by raising up his Basking Bulb away from the tank a few inches, waiting an hour or 2, then re-measure all 3 temperature zones again to ensure that the temps have gone down into the correct temperature zones (Cool Side Air between 75-80 degrees F maximum, Hot Side Air between 88-93 degrees F maximum, and Basking Spot Surface Temperature between 100-105 degrees F maximum; 110 degrees F should be the absolute hottest SURFACE temperature anywhere inside his tank, and 93 degrees F should be the absolute hottest Air/Ambient temperature anywhere in his tank...there is a bit of leeway with the Air Temps, but 110 degrees as the hottest Surface Temperature anywhere in the tank is crucial)...