Mexico’s president wants Patrick Crusius — accused of slaughtering 22 people at an El Paso Walmart — extradited and tried there as well as in the US, he announced this week.

President Andrés Manuel López Obrador made the call during a Wednesday speech in the southern state of Oaxaca.

Crusius, 21, told authorities he was targeting “Mexicans,” according to an arrest affidavit.

He is also believed to be the author of an online rant posted before the shooting that complained about a “Hispanic invasion of Texas.”

“I am simply defending my country from cultural and ethnic replacement brought on by an invasion,” the rant reads.

Crusius has been charged with capital murder, and El Paso District Attorney James Esparza said he would seek the death penalty.

The alleged gunman is being held without bond.

In the past, Mexico and the US have had an arrangement in which a suspect convicted in one country can immediately be extradited for trial in the other, and then serve a sentence in either nation. El Paso is a predominantly Latino city that borders Mexico.

With Post wires