Simmer beef or chicken broth with onion, ginger, star anise, cinnamon, cloves, and coriander seeds for 1–2 hours.
Strain the broth and season with fish sauce and a pinch of sugar.
Cook the rice noodles according to the package instructions and divide them among serving bowls.
Add thinly sliced beef or cooked shredded chicken over the noodles.
Pour the hot broth over the meat to cook it gently.
Top with bean sprouts, Thai basil, cilantro, and sliced green onions.
Serve with lime wedges and sliced chili on the side.