He served as viceroy from September 16, 1635 to August 27, 1640. Born in Peru, Lope Díez de Armendáriz was to become the first New World-born viceroy of New Spain. The son had a distinguished career in command of the convoys escorting merchant ships and treasure ships from the Indies to Spain.
On April 19, 1635 King Philip IV named him viceroy of New Spain.
He made his formal entry into Mexico City on September 16, 1635 and took up his duties. His first concern was to continue the construction of drainage works to safeguard the city from the perennial floods, and to repair damage from recent flooding.
On January 17, 1637 an earthquake destroyed some of the construction, in particular the drainage tunnel Louisiana Quemada. The viceroy called in two experts, Fernando de Zepeda and Hernán Carillo, for advice.
In March of the following year, they advised the opening of a canal to replace the tunnel.
The viceroy, in consultation with the city government, the Audiencia, and the guilds, approved the construction of a canal to take advantage of the huge fissure of Nochistongo. This canal proved very helpful in flood control, and was afterwards expanded by the government of independent Mexico. On April 22, 1639 a bull of Pope Urban VIII prohibited slavery in Latin America.
Philip IV banned slavery of the Indians in New Spain, but permitted the continuation of black slavery.
Escaped black slaves (cimarrones) took refuge in the mountains, particularly in the current state of Veracruz. To protect the inhabitants of the New Kingdom of León (Nuevo León) from raids by Apaches, Comanches and Lipanes, Díez de Armendáriz ordered the construction of a presidio at Cadereyta, and also another fort of the same name in Querétaro.
He sent another expedition to the Californias, with disastrous results. He ordered the cleaning of the drainage ditches and canals of the city.
He founded the Hospital Espíritu Santo and the convent of San Bernardo.
He also formed the Armada de Barlovento, based in Veracruz, which patrolled the Gulf coast to protect the ports and shipping from pirates. He turned over the government of New Spain to his successor, Diego López Pacheco, 7th Duke of Escalona, on August 28, 1640. He was accused of many irregularities and character flaws by his enemies, chief among them the bishop of Puebla, Juan de Palafox y Mendoza.