When their sleep gets better. Whether that's weeks, months or years 🤷♀️
So for my first, by 2 weeks (but then it all went to hell at 4m, and she sleeps worse now at 5 YEARS then 5 weeks.)
For my second, it got easier about 6 weeks, then HARDER (as in newborn was a doddle in comparison) from 6-18m, then good from 18m-2.5, then mixed/hard since.
At the moment (she's 3) I'm surviving on 3-4 hours broken sleep a night - more than the awful 6-18m stretch, but less sleep then when she was a newborn.
I also know those whose children either slept through v early, or at least steadily improved in one direction.
For me, I adored newborns and didn't find their sleep (or lack) to be difficult. But I found later much more challenging (more demanding and slept worse). But those that hate the newborn stage tend to say it improves after about 3 months.
Realistically, it's probably going to be up and down for a while.