You should double check the rules, and this is a pain in the ass and potentially problematic given that it will be harder to find a tenant during a pandemic, but if you rent for four years you should be able to do a 1031 exchange and avoid cap gains. You move out, and rent your existing home for at least 2 years, then do a 1031 for the new house, then rent that one for at least 2 years. If the old and new property are rented for at least 2 years, i believe there is a safe harbor that deems them investment properties for purposes of a 1031 exchange.
You still have the problem of much higher property taxes due to prop 13 though.