The village of Pioz was "devastated" by the gruesome discovery of the four bodies on Sunday and has declared two days of mourning in the village - around 60 kilometres (40 miles) northeast of Madrid - Deputy Mayor Sandra Marin said.
Police said there was no evidence of a break-in at the house and they suspect the bodies had been inside for about a month.
"There was no signs that any door, any window was forced open," a police spokesman said.
"We are still not sure about the motive. It seems like it was carried out by professionals," he added.
El Pais reported that investigators suspect the family was murdered "to settle accounts".
"The deaths were quick, there were no signs of torture. They did not suffer," a source close to the investigation told El Pais.
The family were from Brazil and while their ages have yet to be confirmed, the two boys were "very young," born in 2015 and 2012 and thus around one and four years old, the spokesman said.
Police said they could not give further details while the investigation was underway but Spanish media reported that the bodies were found in plastic bags that had been sealed shut with tape.
Officers were called to the scene after neighbours reported a strong odour emanating from the house, which has been cordoned off by police.
Neighbours said the family were renting the house and had not been seen since the end of August.
Pioz, which has a population of around 4,000 people, will mark a minute of silence on Tuesday at noon in honour of the victims.
"We are very shocked. It is a quiet village," Marin said.