sure.. best to sanitize in some way to avoid any carryover issues or something lurking that needs more time to be a catastrophe. Also, need to amend it again with various fertilizers unless you intend to treat it like a soilless substrate or know it has plenty of nutes remaining from your fertilization in flower etc.. either way, probably has a low nutrient content compared to new soil.
i say that only to cover my bases. i reused my soil for 2-3 cycles before i switched to soilless. small sample. but shows it isn't a super high percentage risk to do so without taking any precautions... and common sense to not re-used a pot that had an unhealhty plant related to rootzone. One other thing -- the substrate breaks down over time. it will lose water capacity over time. if it can't hold water, it can't feed the plants. drainage qualities will change over time too as it breaks down more.
Roots can rot, which invites any random microbe to get a foothold, carryover diseases you didn't notice, yet, and other risks are introduced when doing this. if you re-amend and sanitize it, it's not a risk at all, but just re-using it without any maintenance is a bad idea -- eventually it will cause a problem even if it takes years of doing it.
always good to put things in perspective. for 3-4 plants it might cost 20$ for soil, but you'll spend 300+ on electricity. IMO, if it adds more hours of maintenance, i start to consider how much my time is worth vs how much i am saving. if the savings amounts to some paltry sum per hour, i'm going with convenience. just my 2 cents on that stuff. i was huge on trying to re-use and save as much as possible the first year... much happier since i moved away from that strategy, lol. Each to their own on that.