Esperar vs. prever

In Spanish, both 'esperar' and 'prever' can be translated to 'expect' in English. However, there are nuanced differences in how these words are used and the specific contexts they pertain to.

Esperar

Esperar usually translates to 'wait for', but in certain contexts it can also mean 'to expect'. It is more about anticipating a possible outcome based on certain circumstances or information, but without the certainty of it happening. It also often implies a level of hope.
Espero que venga pronto.
(I expect he will come soon.)
Los doctores esperan que se recupere completamente.
(The doctors expect that she will recover fully.)

Prever

Prever is more akin to 'foresee' or 'predict'. It refers to foreseeing an event or situation based on evidence, knowledge, or insight. It implies a stronger level of certainty compared with 'esperar'.
El economista previó la crisis financiera.
(The economist predicted the financial crisis.)
Pudimos prever el mal tiempo gracias al pronóstico.
(We were able to predict the bad weather thanks to the forecast.)

Summary

'Esperar' and 'prever' both can mean 'to expect', but with slight differences. Where 'esperar' represents expectation more as something hoped for without concrete certainty, 'prever' tends more towards predicting with relative certainty based on knowledge or clear signs.