At the Council of Elrond, it is known that:
Saruman is a traitor, thus it’s not possible for the Ring to pass through the gap of Rohan
Nobody has heard any news of Balin and Moria for a long time; and although he doesn’t know for certain yet, Gandalf fears that more than just orcs inhabit Moria (see this question)
The Redhorn Gate (close to Caradhras) is the only surface path to cross the Misty Mountains between Rivendell and Isengard, and is well known for its dangers
Although Gandalf didn’t have any definite plans, his next goal was to reach Lorien.
Looking at this map, the following alternative paths may be observed:
Walk through Enedwaith into Gondor south of the White Mountains. Isengard and Saruman may be avoided by walking far enough in the west, e.g. along the Greyflood. There are some settlements there (e.g. Lond Daer) which can provide basic support.
Take the High Pass and then follow the Anduin valley to Lorien. This would avoid an encounter with Saruman and since there are orcs and wargs west of the mountains as well it wouldn’t be much more dangerous.
Go further north and take the pass close to Ettenmoors.
So why did Gandalf choose the Redhorn Gate to traverse the Misty Mountains, knowing that it is very dangerous and that only Moria would be an alternative if their attempt at the Redhorn Gate failed, even though he surely knew that there were other and possibly safer ways?