America has long served as a powerful role model for the world, based largely on its commitment to its core principles of freedom, equality, and respect for diversity of opinion and religion. The recent call by Donald Trump to ban all Muslims from entering the United States is an affront to these values, and a threat to America’s domestic tranquility and its standing in the world. In an age where words travel instantaneously across the globe, hate speech can have the same force as actions and policies in shaping opinions abroad. It cannot be ignored.

For 70 years the Middle East Institute has worked to build understanding of the region and enhance ties between the peoples of the Middle East and the United States through non-partisan analysis and scholarship. We seek to inform policy discussions, not take sides in the political squabbles of the day. But Mr. Trump’s statements and the disturbing amount of support they have received have made it clear that our mission is more critical now than ever.

This is not a partisan issue, as evidenced by the widespread condemnations from both parties. And it is not a new issue. Islamophobia and xenophobia have a long history in the United States, as elsewhere. But only in darker periods in our history have such extremist attitudes been embraced so brazenly on the public stage. What we face today isn’t simply a lack of cultural understanding, but a willful disregard for it.

Some argue that America has not always lived up to its own ideals and values. This ignores the fact that the United States enshrined its values in its founding documents and codified them in law, inspiring the world. It is worth recalling that America was once viewed favorably in the Middle East for its call for freedom and sovereignty for nations formerly under Ottoman rule and its embrace of values like religious tolerance and respect for a diversity of beliefs.

Tens of thousands of Lebanese and Syrians immigrated to the United States in the early 20th century in search of economic opportunities and a country that would accept them. Today their ancestors make up the large and peaceful Arab and Muslim communities in places like Dearborn, Michigan and Paterson, New Jersey. Unlike in many European countries, these early immigrants have integrated well into American society and rarely faced treatment as second-class citizens.

In more recent times Arab and Muslim opinions of the United States have turned more critical. Most are not opposed to core American values, as so many believe. Rather they are deeply disappointed by the betrayal of these values when the United States engages in behavior antithetical to what it claims to promote.

Many in the region also assume that what we say matters as much as what we do. Those familiar with America’s political system may be able to distinguish between hyped-up election year rhetoric and serious shifts in national policy, but it’s not as clear for people in the Middle East. Many Muslims will wrongly take the views of a fringe American group or individual as representative of an entire population, just as westerners do when hearing of a terrorist attack in the name of Islam.

Mr. Trump’s comments, and the disturbing level of support they have received, send a very negative anti-Muslim message both at home and abroad. Every casual slight erodes the ideals that the United States has stood for to millions of peaceful Muslims. It plays into ISIS’s narrative of Islam being at war with the Western world. It alienates Muslims living peacefully in America. And it further undermines Middle Eastern attitudes towards the United States at a time when we badly need our Arab and Muslim allies in our shared fight against ISIS.

The call to shut out Muslims over security fears also misses a crucial point: our tradition of welcoming visitors from other countries has long been a quiet, but potent force for promoting American values and staunching anti-American sentiments abroad. Polls have shown that what Arabs and Muslims admire most now about the United States are its quality of education and its technological innovations. Countries in the Middle East and North Africa are among the fastest growing sources of international students enrolling in higher education in the United States, according to the Institute of International Education.

When those students return home, they take with them not only a better understanding and appreciation for American culture and values, but also the skills they can use to build more politically and economically inclusive countries. This is ultimately the best antidote to terrorism. Shutting down this opportunity would sever a key source of American soft power and further contribute to the social and economic limitations on Arab youth that has helped drive ISIS’s recruiting efforts.

What Mr. Trump and his supporters fail to realize is that our commitment to building our own national security and the commitment to supporting the interests and aspirations of the people in the Middle East go hand-in-hand. We at the Middle East Institute remain dedicated to efforts to counter violent extremism at home and abroad, as well as to challenging the verbal extremism that fuels it. We see every day the importance of cross-cultural exchanges for building long-term friendships and critical alliances, and we fear that xenophobic language and knee-jerk reactions could undermine all of that work in a heartbeat.