Mexico’s state oil company Petróleos Mexicanos (Pemex) will add more refining capacity to its portfolio with the deal announced Monday to purchase Royal Dutch Shell plc’s share in the partnership that owns the Deer Park refinery on the Texas coast.

Deer Park

The $596 million transaction was celebrated by Mexican officials as yet another step on the nation’s pathway to energy self-sufficiency. Following the deal, the Deer Park, Texas refinery would be the first outside of Mexico to be fully controlled and operated by Pemex.

“This is very good for Pemex and for all Mexicans, and for self-sufficiency,” Energy Minister Rocío Nahle told local press. She added that the talks over the refinery were lengthy and occurred over the course of the last year.

Mexico is also developing an...