Maybe your worries about having a robotic overlord are not warranted in the short term, but losing a job to a robot might be a fact of life that’s just around the corner. A new study predicts that up to a third of all American jobs will be lost to automation within the next 13 years.

The study by McKinsey Global Institute, a think tank that specializes in business and economics, says that nearly 70 million U.S. workers would have to find new occupations by 2030. This will happen due to advances in robotics, artificial intelligence and machine learning. 

Machines will become better than humans at a variety of skills, including some that require cognitive abilities. Automated technologies will also be producing significantly fewer errors, allowing businesses to improve productivity, quality and speed. Employing humans will become an illogical option in some professions. People would need retraining or enter completely new fields, concludes the report’s co-author, Michael Chui, a partner at the McKinsey Global Institute.

“We believe that everyone will need to do retraining over time,” he said, according to the Washington Post.

The researchers believe the coming changes will affect people across different career levels. Certain sectors will be affected more than others. By 2030, the demand for office workers, including anyone involved in administrative tasks, should fall by 20%, predict the researchers. Up to 30% of the people in jobs requiring “predictable physical work” like in construction or the food industry, for example, could lose their jobs as well. 

These are the types of activities inherent in some jobs that are more susceptible to be replaced by automation:

Jobs that require creativity or more human interaction, like being a lawyer, manager, a doctor or a teacher would be less under the knife from automation, think the scientists. There could also be new type of jobs in supporting the technology that will arise. 

The changes won’t just hit the U.S. but will reverberate around the world. The scientists say that up to 800 billion employees perform “technically automatable activities” and will find themselves out of that work by 2030. On the flip side, the researchers say up to 280 million new jobs could be created from increased spending on consumer goods and another 85 million jobs from more spending on health and education. 

These are the U.S. industries most likely to be affected by automation:

The authors see the looming transformation akin to what happened in the United States and Europe in the early 1900s, when global industry switched from farming to factory work. Overall, their message is not one of doom. They do not want to scare people but rather prepare for an inevitable transition, especially highlighting the need for mass retraining.

You can learn more about the study and read it here.