The U.S. could face a shortfall of thousands of doctors, experts warn, because Pres. Donald Trump issued an executive order last week that banned citizens of seven majority-Muslim countries from entering the U.S. for 90 days. The order has created fears among foreign-born doctors and medical students—more than a quarter of the physician workforce in the U.S. comes from other countries, including Syria and Iran—that they will be persecuted in the U.S. or forced to leave. Medical school leaders say that sought-after applicants are likely to move their careers to other countries.

The reasons such doctors are in the U.S. in the first place is that America does not produce enough physicians to keep up with demand. A current deficit of 8,200 primary care doctors and 2,800 psychiatrists is expected to worsen as the population grows and ages, according to a report published in 2016 by the Association of American Medical Colleges (AAMC). It estimates the U.S. will face a shortage of up to 94,700 doctors by 2025. Almost a third of the crunch will be primary care physicians

More than 8,400 doctors working in the U.S. are from two countries listed in the executive order—Syria and Iran—according to data from the American Medical Association. Even more foreign-born physicians—close to 50,000—are from India, which is not included in the travel ban. But the fears created by last week’s executive order will ripple across Asia and the Middle East, reaching places like India, says Atul Grover, a physician and executive vice president of the AAMC. “The majority of our foreign doctors come from India and Pakistan, and while they’re not on the list I think when the environment feels this uncertain and this inhospitable, they’ll go to Canada and the U.K.,” he says.

Doctors themselves say that Grover is right. Omar Alsamman, who practices in New Hampshire, wishes he had gone to work in the U.K. instead. Alsamman left Syria in 2011 after completing medical school. He did his residency in New Jersey in internal medicine. “I’ve been in paralyzing fear since the executive order was signed. My H1-B visa expires later this year and I don’t know if it can be renewed. I only came here to accomplish the American dream. I found love here. I found a home here. Now everything is in jeopardy.” Although the executive order does not mention immigrants who are already in the U.S., he says some immigrant doctors will leave and pursue their careers in a country that is more welcoming.

Medical schools say the order makes it harder to recruit newly minted MDs to work in hospitals as resident physicians, says Jessica Bienstock, associate dean for graduate medical education at Johns Hopkins University School of Medicine. By the end of February, teaching hospitals across the country have to select the newly qualified doctors who will help staff their wards beginning in July. It is a highly competitive process known as matching. “But now we’re in a position where we could match someone who is from Syria or Iran and they won’t be able to get into the country,” Bienstock says. “And if we do match someone who can’t enter, then we end up running a residency program with holes in it and not enough doctors to take care of the patients that the program is responsible for.”

Bienstock says she is advising doctors who are from foreign countries not on the list, particularly African and Middle Eastern doctors, that they should not leave the U.S. “There’s lots of jitteriness and uncertainty among our trainees,” she says. Although the executive order does not mention vetting non-U.S. citizens who are already in the U.S., Bienstock fears that an extension or broadening of the ban would prevent foreign doctors from returning to their patients if they left the country. Other nations could be added to the order, White House Chief of Staff Reince Priebus told NBC News in an interview on Sunday.

Kinan Alhalabi, a Syrian who trained in the suburbs of Damascus, is one of the young doctors worried about the match and the ban. He has been in the U.S. for two years and has done stints at top hospitals such as the Cleveland Clinic and the Mayo Clinic. In recent months he got job interviews at a dozen hospitals to be a resident, he says. But in the aftermath of Trump’s order he e-mailed all the hospital program directors at the hospitals, anxious to hear if the order will affect his chances. So far, he hasn’t heard back, he says. His work permit is scheduled to run out this summer and if it is not renewed, then he will not be able to be a resident, leaving any hospital that accepted him as a resident short-staffed. “I just paid my taxes,” he says. “I see 30 American patients every day and try to heal them. It’s devastating after all this work to help American society and be a part of it that with one [presidential] signature everything could just fall apart,” he says. He and other Syrian medical students that he has been communicating with in a Facebook group are starting to think about applying for foreign residency programs in Germany, Switzerland or the U.K.

These concerns are also affecting scientists, hampering their work. Some European scientists working in the U.S. have been advised by immigration lawyers to cancel travel to international conferences until details of the executive order are better understood. A Belgian researcher based in the U.S., who requested anonymity because he fears retaliation from the immigration service, says he had to cancel a field trip to study malaria in Southeast Asia. “It makes you think twice about starting a career in the U.S.,” he says. “It’s nothing compared to what people from those seven countries are going through, but it doesn't make you feel accepted.”

A similar phenomenon occurred after the attacks of September 11, 2001, when stringent visa controls prevented some scientists from working in the U.S. Albert Teich monitored the impact of the travel restrictions on science for the American Association for the Advancement of Science, and now researches visas and immigration policies at The George Washington University. “It looks like we’ve gone back in time,” he says. “This is an echo of what we did in 2002 and 2003. Back then it was driven by panic. You could maybe understand it. What’s happening now is a politically driven self-inflicted wound.”

Teich says it is difficult to measure the direct impact these types of restrictions have on the academic landscape of a country—but the net effect is negative. These policies keep out good scientists and make scientific collaboration and communication more challenging, he says.

A slowing down of scientific advancements might not be as tangible, however, as longer waiting times in the clinic. Grover, whose organization includes all 147 accredited medical schools in the U.S., worries most about foreign doctors seeking employment elsewhere. “There’s so much uncertainty,” he says. “Today it’s seven countries on the list. Who knows what it will be next year or even next week?”

Additional reporting by Dina Fine Maron