Hair balls are caused when your cat ingests loose hair and dirt and it gets caught in the stomach and will not pass out as feces. Therefor help your cat eliminate loose hairs and dirt so less has to pass through his/her stomach. Groom aka brush your cat once a day or once every other day. This will eliminate alot of loose fur in your cats coat so your cat will not digest them. Also, if possible give your cat a bath or take him/her to the groomers once a month.
Clean your house. My suggestions is that you run the vacuum in every room of your house that your cat roams and sleeps. Doing so will pick up dirt and loose fur laying or floating around. Vacuum furniture as well if possible. If you cannot vacuum your furniture, use tape or a lint roller on the surfaces.
Next you should mop with Lysol cleaner. The cleaner will disinfect your floors that could have caused illnesses for your cat as well. Also, by mopping you are also picking up excess hairs left on the floor after vacuuming.
Now you have a clean house, AND a clean cat. Clean your house like this once a week or every two. But you cat will need to be groomed more frequently. Remember that your cat sheds everyday and you will need to eliminate the hair in your house and on your cats coat to decrease hair balls. Happy cleaning!!!!