I don’t think there is a specific age, as it needs to be the child’s preference as well as the parent. In general though, I would say not before six months of age at least.
I had my own children in an era when infants were routinely put into solitary confinement during the day on beds or blankets on “the floor” of an adult room — while their mothers worked. This practice holds two contradictory views of children – that they are noisy and toxic, needing containment; but also that they are trainable subjects to develop will power over self-comfort regulation. Ultimately, after all these years studying pediatric habits and behavior, I believe babies should sleep with their families in their securely enclosed cribs for both mental health.