The ministry said in a statement carried by the SPA state news agency that the two Pakistanis were found guilty of storming the house of a foreign family and raping a woman before stealing her gold jewellery, mobile phone and some cash.
They were executed in the capital.
The total number of executions reported in the Gulf kingdom in 2010 is now 21.
There were 67 reported executions in Saudi Arabia in 2009 and 102 in 2008.
Murder, rape, armed robbery, apostasy and drug trafficking are all punishable by death under Saudi Arabia’s Islamic sharia law.