Sleeping/Pregnancy pillow

I’ve been told you shouldn’t sleep on your back or stomach while pregnant but I don’t know when to buy a pillow. I wake up once each night from GOOD sleep but I find myself sleeping on my back.

When did you start sleeping with a pregnancy pillow to control your sleep positions?