The actual initial equipment investment is about the same for a competition dirt bike or an entry level street motorcycle. (~10 grand) But it depends on places you have to ride it, you either need street insurance and a plate or you are good with riding it on private lands and closed course competitions.
It's a life style choice.