A number of things:
--My first bit starting at 6 months and never stopped. For him, it was a signal he was done, so removing him from the breast was not a punishment. What caused it? He had bottled breastmilk 4x a day at daycare, and he would teethe on the nipples. We got to the point where I pumped more than nursed, which was fine.
--Most kids, I think, accidentally bite when they first get their teeth. My second did, and at 21 months, we're still nursing without biting at all. The trick is to teach them to not do it--show them you are hurt and displeased. My first thought my expression of pain was funny, which was hard. I had to school myself not to react in my usual way to send the message.
--A friend has grabbed the checks of her baby and smooshed them together to discourage biting. She claims it works very well.
--I've also heard advice that suggests you either stop nursing when baby bites or to push baby's face into the breast (obviously, not suffocating your child, but making it more difficult to bite).
--Finally--my second is a very hard sucker, and even when he's not biting, his teeth scrape my nipple. I have teeth marks around my nipple when he nurses hard, which is not all the time. I know he's not biting; biting is a shock and this is more a gnawing. If this is what's happening...well, then let me know if you get advice on it; I've just been putting up with it!!!