The fire broke out on Saturday in a nature reserve in the Guadalajara area east of Madrid after visitors failed to put out a barbecue properly.
By Sunday night it was spreading out of control after scorching thousands of hectares of pine trees and brush.
Parched by a heatwave and the worst drought since the 1940s, much of Spain is like a tinder box and fierce fires are burning in several regions.
Jose Luis Samper, mayor of the town of Riba de Saelices, near where the deadly fire began, said a fire patrol that had come from nearby Soria province to help was surprised by the flames and trapped in a remote spot.
"After they had been missing for more than two hours, some people from this village ventured out ... and finally found them.
"There was only one survivor. We don't know exactly how many bodies, but they found at least 12 bodies, absolutely burned."