Depending on what the slope is and rainfall, you have different options.
A retaining wall is one, and really a worst-case scenario alternative for slopes that are really steep where nothing else will work, or you’d like to have a wall.
Other options include:
Mulch. This can be used in conjunction with the other ideas below, or alone in the case of a slope that’s not too steep.
A third option is to install a “living wall”; something like this. You lay the netting over the area, and plant a stabilizing ground cover or other plant beneath it. When the plant takes the area over, the netting and its roots hold the soil in place. They are often made out of plastic, but other materials are available. Here is one made out of jute.
Also on that link are the “straw waddles”. You can place these along the bottom of your slope to prevent anything that does manage to run off from continuing on further. They also hold water and slow the flow of water down thereby giving the soil more time to absorb it and helping to prevent/reduce erosion. I think you can also place these along the grade of the slope to help slow the water down. They also come in different materials I think. They are also sometimes called “socks” and you can self-fill them with mulch.
You can also consider terracing.