Apparently it releases endorphins.
I've done it many times over the years, usually in phases when I'm going through honeysuckle I can't deal with. Started off as scratches but over time it got worse, I'd grab a meat carving knife, roll my sleeve up, hold the knife against my skin and in one swift slice I'd tear myself open, and watch it start to cry before frantically trying to stop the bleeding with copious amounths of tissue and pressure. Then I'd walk to casualty and get it stitched up, and come home and go to bed.
I'd feel very delicate the following days, taking care not to bump into anyone or anything, constantly feeling the bandaging under my clothing, and, although guilty and ashamed, it made me feel cared for. It wasn't at all a sexual thing nor would I call it a fetish, but there was something very nice about the feeling of being looked after, taken care of.
But why did I do it? There are many theories as to why people do it, the main one being for attention. I guess the whole wanting to be taken care of thing is attention seeking, but it was just from strangers... nurses... it was never something I wanted to share with people I knew, and every day I try to hide my scars. I've often thought it was a good way to constantly hide myself, to not let myself have too much fun, at the beach, the swimming pool, the whatever activity that involves being somewhat naked... including sex. A way to hide, to stop myself getting too close to anyone. This is just theory though. Probably partially true. The main reason is that I can't deal with mental or emotional pain, and would much rather physical. Also, seeing yourself bleed like that is a real slap in the face, a great distraction from the shitty feelings, when no amount of cognitive practice, talk therapy, or physical exercise will help. Plus the afore mentioned feeling of delicacy and softness that would occur the following days. Music would sound better. Films seemed more appealing. Some things would just look a bit more beautiful after an ordeal.