When is a good time to have your baby sleep in their own room?

As a first time mom, I'm trying to get everything I need to to know figured out before baby gets here. I know I'm not going to co sleep and I know I want baby I their own room as soon as possible to help with getting baby used to falling asleep without us there. When did you start having baby sleep in their own room? What was the hardest part and what was the easiest part? any tips or tricks you did to help them sleep?