> But if you find a niche market
Therein lies the rub. If the market you find is too niche¹, then any product you produce for it will likely be unprofitable, so defining exactly what niche means in this context requires bounds.
So now it's a game of shopping around for the right niche market. If you're lucky, then you'll find one which aligns with what intrinsically motivates you. If not, then it'll be a grind to become enough of a SME in that niche market segment to produce a product which meets the needs of its participants.
I therefore argue that step 1 is to be a normal enough person to have some niche interests, but ones which are not so niche that you only share this interest with— at most —a few thousand other people.
[1] The owner of The Laserdisc Database, lddb.com, doesn't make enough solely from this venture to support himself.