If you go through the military or have rich family members to cover the cost and you like it then sure. If you get into your state school and get in state tuition, you need to really like it and have a good plan. If you only get into out of state or private schools, then probably not. From a financial standpoint, you should evaluate other options.
From a personal note, I was dead set on doing a PhD in economics my junior year of college. I was doing research with a professor, working as a TA, reading everything I could get my hands on, and taking advanced level math classes to have an attractive application to a top 10 program. Then I took 'Real Analysis' with a guy who hated teaching undergrads and failed everyone but 4 or 5 in a class of 30-35. I could've retaken the course with another professor and continued down my PhD path, but I didn't because I realized it kinda sucked for me to be in studying all the time instead of enjoying football games and hanging out with friends occasionally. But I still felt lost and really stressed out.
I went to the library and read a bunch of books on what people do with their lives, and I took the first level of the Charted Financial Analyst program in my senior year of college. Leveraged that into a corp job after graduation and things have turned out just fine.
I say that bc the vitriol of some people's reactions is clearly coming from an emotional place. People are upset bc I'm messing with plans they've had for years. I get that. Just realize you're not a failure if you change course. If you go to school and have to call me in 4-5 years, that's obviously great for my business. Just have a plan and don't go into it blind thinking your education is your ticket.