Hind leg degeneration can be caused by trauma to the spinal nerve from things such as a rat jumping off something high off the ground and hurting themselves or by being dropped. It also happens quite frequently to elderly rats as they age and their spinal nerve degenerates. It's a gradual process but there are things you can do to help your rat be more comfortable when he is no longer able to move around like he did when he was younger.
Move Things Closer
Marbles and a couple of my other rats had hind leg degeneration and they didn't move as well as they used to. So I put them in a small single level cage and moved everything closer to them.
Move the water bottle closer to your rat so they are able to get to it when they want to. Move the food dishes, treats and any toys closer to where your rat sleeps. I actually had to take out all the food bowls and pile the food in the corner so he could reach it easier. Just make sure to clean up any food from the cage floor each day so your rat isn't dragging his belly over it, which could cause scrapes and abrasions and lead to abscesses.
Your Vet should be able to tell you whether or not an animal acupuncturist would be of benefit to your rat. If he is younger and in otherwise good health it is your responsibility to try all methods that could help your rat live a long healthy life.
If your rat seems to be having a hard time walking, is dragging their tails more instead of keeping it raised as they walk around, you should take your rat to a Vet and have them looked at. Your vet may prescribe anti-inflammatory medications, steroids or antibiotics. Or they may tell you to just keep them as comfortable as possible.
A rat who cannot use his back legs is going to need help grooming himself and keeping clean. Because he cannot use his back feet he will need help cleaning his ears, his belly, his privates and may become incontinent so his bedding will have to be changed daily where he sleeps if he urinates on it.
You may have to check his privates for dried feces and urine and wash that off. If he isn't able to clean his private area he may develop sheath plugs which are waxy plugs in the penile sheath and need to be removed or they can cause urinary tract infections and pain.
Because rats with hind leg degeneration mostly scoot and drag themselves through bedding and cannot walk on top of the bedding, you'll need to change the type of bedding you use. Bedding such as pine, crumbly paper bedding and any other crumbly type bedding is not suitable. You'll want to use fleece blankets or fleece material and cover the bottom of the cage so that the material is nice and flat and your rat can move around easily without getting any fleece material bunched up under him.
I use a fleece animal bed for my rats who had hind leg degeneration and a small cotton baby blanket in it for them. Rats with hind leg degeneration can live a happy life if given the extra help they need.