Spanish Civil Guard officers stand guard in a checkpoint at the Spanish-Portuguese border between Tui and Valenca, on March 16, 2020 | Miguel Riopa/AFP via Getty Images Spain and Portugal partially seal their borders Decision comes as Brussels urges national capitals to act with restraint in imposing new border controls.

Spain and Portugal became the latest EU countries to partially seal their borders Monday to stop the spread of coronavirus, despite an appeal from the European Commission to act with restraint in imposing new border controls within the bloc.

Spanish Interior Minister Fernando Grande-Marlaska announced that the country would severely restrict border crossings from midnight on Tuesday, and until the "state of alarm" declared by the government last Friday ends. It was set to last 15 days, but could be extended.

"Only Spanish citizens and those who can justify crossings for reasons of force majeure will be permitted to enter the country by land," said Marlaska, who explained that Spain had adopted the measure following the example set by other EU countries. Germany partially closed its borders on Monday morning, while the Czech Republic, Denmark and others sealed their own crossings last week.

The minister clarified that foreign diplomats would also be allowed to move freely, and that the restrictions will not affect the transport of goods needed to keep Spanish pharmacies and supermarkets stocked.

In Portugal, Internal Administration Minister Eduardo Cabrita announced similar measures on its only land border, which it shares with Spain. Most of the roads that cross between the two countries are to be blocked, with only nine remaining open, one in each of the country's border districts.

The transport of goods and cross-border commuters will be allowed to pass, but "all other transit will be absolutely prohibited."

The minister clarified that Portuguese citizens and residents will be allowed to enter the country. On Sunday, the Portuguese Foreign Ministry issued an alert advising citizens currently traveling abroad to come home.

The leaders of Spain and Portugal, Pedro Sánchez and António Costa, made the decision for the Iberian peninsula in coordination with one another. The pair had discussed their options on Sunday and teams from both governments selected the crossings that would remain open and also set technical requirements for the border controls.