WASHINGTON — As we bear witness to the global democratic recession, we cannot afford to ignore the increasing militarization of societies in Latin America, which has coincided with illiberal trends in other parts of the world. After President Trump’s ill-advised suggestion to use the United States military to secure our southern border, the administration has an opening this week to demonstrate commitment to our core principles by stating its opposition to the militarization of law enforcement, which represents a challenge to liberal democracy across much of Latin America.

As James Mattis embarks on his first trip to South America as secretary of defense, he has the opportunity to declare United States support for police and judicial reform as the best method to fight crime and violence. It is the perfect time to highlight the dangers of militarization; three of the four countries on the secretary’s itinerary — Brazil, Argentina and Colombia — have to varying degrees turned to their armed forces for domestic security. Unfortunately, as we’ve seen in Mexico, reliance on the military jeopardizes the protection of human rights and can actually exacerbate citizen insecurity.

Secretary Mattis will begin his trip in the Southern Cone before traveling to Colombia. Given the military’s participation in past repression in Brazil and Argentina during the dictatorships of the Cold War, the deployment of the armed forces to supplement and sometimes even supplant the police is particularly alarming. Military operations in the favelas of Brazil have become commonplace, and the Brazilian Army is currently in charge of Rio de Janeiro’s police force. The front-runner among eligible candidates for Brazil’s October presidential election, the retired Army Capt. Jair Bolsonaro, would most likely increase the use of troops to fight crime. After all, he has suggested that security forces should have greater impunity to shoot criminals, and he has expressed nostalgia for Brazil’s 21-year military dictatorship, whichhe has called “a time of glory.”

Concurrently, Argentina is taking the first steps down the path toward reliance on the military for internal security. Last month, President Mauricio Macri announced the deployment of troops to the northern border region to work alongside the police to counter illicit trafficking. And in the case of post-peace-accord Colombia, President Iván Duque will continue to rely on the armed forces in the ongoing struggle against criminal bands, the National Liberation Army and former Revolutionary Armed Forces of Colombia members who have refused to disarm.

The need for security is urgent and undeniable, but the Mexican case illustrates that the military is not the solution. Since 2006, when President Felipe Calderón summoned the armed forces to lead the struggle against violent criminal organizations, violence and crime have increased dramatically. Last year the homicide rate reached 25 per 100,000, the highest rate since the Mexican government began keeping track. A staggering 48 percent of Mexicans feel unsafe in their neighborhoods, and 19 percent feel that they must move because of fear of crime.

The Mexican case also demonstrates that deployment of troops to the streets leads to human rights abuses. Military doctrine is not oriented toward the responsibilities of law enforcement, and Mexico’s National Human Rights Commission has reported almost 10,000 complaints of human rights abuses by the military since 2006, including torture, forced disappearances and extrajudicial killings. In my conversations with Mexican military officials at the highest levels, a common theme has been that they want to get out of the law enforcement business so that they can return to traditional defense activities. They recognize that the risk to their reputation grows the longer they are operating in the streets.

Mexico’s track record reveals another important danger: Once a country starts down the path toward militarization, it is difficult to change course. Both Mexico and Colombia illustrate that reliance on the military weakens the incentive to strengthen the police. When Calderón deployed the military 12 years ago, it was meant to be short term. Last year, however, Mexico passed an Internal Security Law that institutionalizes the domestic role of the military, further normalizing and prolonging militarization.

In his bilateral meetings and public remarks, Secretary Mattis should emphasize United States support for overhauling law enforcement and strengthening the criminal justice system to address the impunity that plagues much of Latin America. Until nations have the institutional capacity to hold criminals accountable for their actions, citizen security is impossible. And only after the police have the ability and incentives to meet their legal responsibility of providing public security will governments relieve the military of the internal security mission.

Rebecca Bill Chavez served as the deputy assistant secretary of defense for Western Hemisphere affairs from 2013 until 2017. She is a nonresident senior strategic fellow for Latin America at the Fletcher School of Law and Diplomacy.