The most important step in getting rid of rats in the walls is to figure out how the rats got in there in the first place and seal off those entry points. This means you must do a full inspection of the entire house; remember that rats in the walls did not necessarily enter the house through those walls. They can travel from any point in the house, and they can often chew through housing materials such as wood, insulation, and even concrete. Sealing off the entry points should be done with materials that the rats cannot chew through, such as steel plates.
Several methods for getting rid of rats in the walls exist, but one of those methods should generally be avoided: poisoning the rats may kill some of the rats, but it will not eradicate all of them, and when the rats die, they may die within the walls. This means the carcass of the rat will stay within the wall, decompose, and begin to stink. Rat traps are a more effective way to kill rats, since the dead rats can be easily located and disposed of. To get rid of rats in the walls, traps must be set strategically where the rats will travel regularly. This may mean setting traps in the attic or basement, or near the entry points where the rats got into the walls in the first place.
Remember that rats can carry many diseases and can contaminate water and food. If the rats in the walls have been traveling throughout the house, it may be necessary to decontaminate the house with a thorough cleaning once all the rats have been exterminated. Remember, too, that rats will chew on materials within the walls, including wiring. This can lead to a fire hazard, so if you suspect rats have been eating away at the materials within the wall, you may need to replace any damaged wires.
Seal off any cracks, crevices, or openings that may allow rats in the walls to come and go as they please. Sealing off the entrances will prevent more rats from entering and the rats already within the wall from leaving. Be sure to cover these openings with materials that the rats cannot chew through, and do not ignore tiny openings; rats can squeeze through very small cracks and crevices, so be thorough. Set traps in strategic locations once the entrances and exits have been sealed off, and dispose of the dead rats immediately. Be sure to wear protective equipment such as glasses, gloves, and in some cases, even gas masks.