There's good evidence that the younger a couple is at the age of marriage, the more likely they are to get divorced. (Correlation does not imply causation, etc., but some correlation exists.) A psychologist I know said that the developmental changes that occur between the ages of 20 and 24 pale in comparison to the developmental changes that occur between 24 and 27. From my personal experience, I wholeheartedly agree. I was a dramatic, insecure, emotionally immature mess at 22. (I like to think I'm better now, but you'd have to ask the boyfriend.)
It depends on you, your boyfriend, and the maturity and health of your relationship. If I'd married at 22, I'd be miserable. I hadn't seen at that point what a good, healthy relationship looked like. It took me until I was almost 25 to finally figure out what the right type of person is for me and then see what kind of relationship I was capable of having with him (which is perfect).
Marrying young isn't inherently rash or imprudent, but I think there are some things to be particularly aware of, and it's a decision to be made carefully after you reflect honestly and rationally on your own situation.