"My deepest condolences on the death of the Spanish soldier in Lebanon. My sympathy and condolences to his family and friends," Rajoy said in a post on Twitter.
Francisco Javier Soria Toledo, 36, who served in the 10th Guzman el Bueno brigade in southern Spain's Cordoba, has been stationed in Lebanon since November 2014, Spain's Defense Ministry told RIA Novosti.
Tensions along Israel's northern borders heightened on January 18, when an Israeli helicopter reportedly fired missiles at a group of militants near the Syrian town of Quneitra, on the border with Golan Heights.
The attack claimed six lives, including that of Imad Mughniyeh, the son of Hezbollah's late top military commander. Hezbollah pledged that the response to the killing of its members would be "fierce" and "destructive."
Hezbollah is a Lebanese Shiite political party and militant group established in the 1980s to oppose Israel's occupation of Lebanon. It is considered a terrorist organization by Israel, the United States and a number of Western countries.