Young children should not spend more than an hour a day watching television and videos or playing computer games, according to the World Health Organization (WHO).
It also says that infants less than one-year-old should not be exposed to electronic screens at all.
The United Nations agency, issuing its first such guidelines, said under-fives should also be physically active and get adequate sleep to help develop good lifelong habits and prevent obesity and other diseases in later life.
"What we are cautioning on is over-use of those electronic screen times with young children," WHO expert Dr Fiona Bull told a news briefing.
In its guidelines to member states, the WHO said children between one and four years old should spend at least three hours in a variety of physical activities spread throughout the day.
Infants under one should interact in floor-based play and avoid all screens, it said.
Being inactive is fueling a rise in the numbers of obese or overweight people worldwide, the WHO said. Excessive weight can lead to premature death from heart disease, diabetes, hypertension and some forms of cancer.
"Preventing these deaths needs to start in very early life," Dr Bull said.
One in three adults today are overweight or obese, and one in four adults does not do enough physical activity, she said.
"In this age group of under 5s, it is currently 40 million children around the world (who) are overweight. Of that (figure) 50% are in Africa and the southeast Asia region," Dr Bull said. That translates into 5.9% of children globally.
Early childhood is a period of rapid physical and cognitive development during which habits are formed and family lifestyle routines are adaptable, said the WHO guidelines, drawn from evidence in hundreds of studies, many from Australia, Canada, South Africa and the United States.
"Sedentary behaviours, whether riding motorised transport rather than walking or cycling, sitting at a desk in school, watching TV or playing inactive screen-based games are increasingly prevalent and associated with poor health outcomes," the WHO said.
Chronic insufficient sleep in children has been associated with increased excessive fat accumulation as measured by body mass index, it said.
Shorter sleep duration has been associated with more TV viewing and time spent playing computer games, it added.