Andrés de Pez y Malzarraga (Cadiz, 1657 - Madrid, May 7, 1723) was a Spanish Naval commander.
Andrés de Pez was born into a naval tradition. His father and older brother were Spanish Naval captains. By the age of 16, de Pez had also entered the Spanish Navy, sailing to and from the Americas.
In 1676, he fought the French in the Battle of Palermo, where his brother and father were killed. He then became a company commander in the Caribbean, guarding Spanish ships and colonies from foreign attackers and pirates. He earned a reputation for outstanding bravery and efficiency, being wounded five times.
He was selected to explore and claim the largely unmapped coasts of the northern Gulf of Mexico. He participated as second in command on three of these voyages between 1688 and 1689. Here he saw the opportunities of Pensacola Bay as a deep-water bay that could be easily defended from approach with land.
Pez sailed to Spain to convince the War Council of the need to establish a stronghold along the shores of Pensacola Bay. After much opposition, he finally received funds for an official reconnaissance of the bay, and a promotion to the rank of admiral. Admiral de Pez returned to New Spain (Mexico) in the fall of 1692 and began plans for the expedition that would lead to the first successful European colonization of Pensacola.
De Pez sailed from Veracruz on March 25, 1693 taking with him the pre-imminent scientist and cartographer Don Carlos de Siguenza y Gongora. They carried with them 120 sailors and 20 infantrymen in two ships: the frigate, Neustra Senora de Guadalupe, and the sloop, San Jose. The expedition entered the bay on April 7. Siguenza named the bay Bahia Santa Maria de Galve.
De Pez returned to the south and commanded the entire Windward Fleet until 1701.
During the War of the Spanish Succession, he supported the Bourbon King Philip V of Spain and fought the British, Dutch and Catalans who supported Charles VI of Austria. He served as captain general of the Indies fleet from 1708 to 1710. Pez became in 1715 a member of Spain's Supreme War Council. In 1717 he was named governor of the Council of the Indies, and was named secretary of state and navy in 1721.