Depends on the individual and where.
Worked for me. I still pay less per month than my mortgage was even in it’s last 8 years.
Glad renting worked out for you. Doesn't work for others. My oldest daughter and her husband were renting, paying $2000 a month about 8 years ago. They moved to Iowa and bought a home for $80K, and began fixing it up. When they moved, the former landlord raised the rent to $3000 a month. Daughter and husband own their home with no mortgage at all, big savings. Home now worth about $400K.
When you rent, you don't get any equity when you move out. My youngest daughter was paying $3000 a month rent with her boyfriend, splitting the cost. He left, and it fell on her to pay all the $3000/month rent. We helped her with the downpayment and she bought a home almost two years ago, and the mortgage is a little more than what she was paying in rent. Now that she owns, she gets the benefit of the equity in the home, whereas the old rent payments were like throwing money in the toilet.