calculator
The real math over your timeline. If renting wins, this will say so.
Buying costs include closing costs, mortgage P&I, taxes, insurance, and maintenance. Renting costs include rent (growing 3%/yr) minus investment returns on the down payment.