That would cost you at least thousand if not a million dollar, if you mean those giant browser based RPGs or any gene large ones. Of course u can hire people to code one for you maybe? Not realistic though. Try:
1) buy existing game script/game website
2) buy scripts from codecanyon, itchy.io, sourceforge, etc sites and customize after
3) hire people or co-work with a programmer
The idea usually bad, niche is not good, those making tons of money are often very big company not individuals, even u can code one (I saw once), u still need consistently maintain it and market your game, which IMH, not a good niche at all.