The blaze which broke out on Sunday near the Mediterranean resort of Javea, up the coast from the popular holiday spot of Benidorm, destroyed 320 hectares (790 acres) of land and several buildings, local emergency services said.
Authorities said they believe the fire was started deliberately since it appeared to have broken out in several places at once.
“This is environmental terrorism, it goes beyond putting at risk our natural heritage, it directly attacks people,” the head of the regional government of Valencia, Ximo Puig, told reporters.
“1,400 evacuated,” tweeted Juan Carlos Moragues, who represents the Spanish government in the eastern region of Valencia.
While many of the evacuees were put up in schools, residents of Javea also offered to put them up for the night and gave them food and water, city councillor Maria del Pilar Zamora told private television channel Antena 3.
Photos and videos posted on social media showed flames raging earlier near built up areas.
— Pueblo Acantilado (@PuebloAcantila) September 6, 2016
Several homes were completely destroyed by the fire, Antena 3 reported.
By Monday night, the fire had stopped spreading, an emergency services spokeswoman told AFP.
“The situation is no longer deteriorating; they have stopped the fire,” she said, adding that firefighters would continue working through the night.
Among those who posted photos of the blaze was BBC host Chris Stark who was on vacation in the area.
“We are safe. Thanks for everyone with kind offers of places to stay. Really hope everyone else in Javea is ok. The fires were scary,” he tweeted on Monday.
Holiday day 2. The fire is kicking off again round the back of the appartment. Javea beach corespondent here pic.twitter.com/j4rSpkUCUo
— Chris Stark (@Chris_Stark) September 5, 2016
Firefighters said the blaze had been fuelled by scorching temperatures and low humidity levels.
Most of Spain faced an “extreme risk” of wildfires on Monday due to the heat, with temperatures over 40 C (104 Fahrenheit) in some parts.
The interior ministry warned the scorching temperatures would continue at least until Wednesday, and urged people not to throw cigarette stubs and glass bottles to the ground in scrubland.
“Negligence caused the majority of forest fires,” it said in a statement.
Spain routinely suffers wildfires during the hot summer months but there have been fewer large blazes in 2016 than in recent years.
Wildfires destroyed 39,700 hectares of land between January and August, according to the agriculture ministry.
The average for the period since 2006 has been 78,743 hectares.