Placing garlic cloves around entryways can reportedly prevent infestations. Rats and mice also "hate" the smell of fresh peppermint, so wiping peppermint oil on a cotton pad across any entry ...
Rats are more likely to come into gardens to try and find somewhere warm to burrow for the rest of winter, but if you do not deter them quickly, they can make their way inside your home.