Depending on the extent of a rodent infestation, it can be a challenge to stick with humane pest control methods - but it can be done. Homeowners who need help should turn to the professionals who have the experience and equipment to handle the problem - just be sure to speak up and let them know you prefer humane methods. Keep in mind that some types of lethal traps can be considered humane.
An ultrasonic rodent control device can be used to help encourage rats to leave the house. These devices give off vibrations and/or sound waves that are supposed to be unpleasant to rodents, causing them to leave the area. Unfortunately there have been mixed reviews over whether or not these devices really work. Rats can quickly get used to them and then the devices become completely ineffective.
If you decide you want to give them a try, you will need several of them as the sounds cannot travel through walls. Choose a device that mixes up the pattern of sound so that rats don't quickly get accustomed to it.
One natural rat deterrent is peppermint oil (not extract). Generously dribble peppermint oil onto cotton balls and place them in the rats nesting areas and frequently used pathways. The oil needs to be replaced or refreshed every so often so that it doesn't lose its potency.
Predator urine pellets are supposed to be yet another rat repeller. These pellets do not have an unpleasant scent to humans, but to rats they're supposed to smell like the rat's natural enemies. The theory is that the scent of the pellets will frighten the rats into thinking there are predators around, so the rats leave the area (if you have a cat or a dog, their scent may help detract rodents too! -- but remember that pet food is also highly attractive to rodents, so keep it securely stored in rodent-proof containers). Again, there are mixed reviews about whether 'predator urine' really helps to repel rats.
The absolute best way to keep rats away is to take preventive pest control measures. That means taking away sources access to food, water, and shelter by sealing up our homes and managing our yards. The more we can exclude rats, and the less comfortable we can make them, the more likely they will move on. Prevention is also the most humane way of dealing with unwanted rodents.
Using a rat repellent (or a combination of them) is a useful way to help deter rats... but it's the use of a variety of different things including exclusion and prevention that will keep them away long-term. Once any infestation has been dealt with, it is far easier to take steps to keep rats from returning, then it is to have to once again find a way to remove them from the home.