Spain stayed out of the war and didnt even lethitler use his ports for his north african campaigns. He realized, unlike the other fascist dictators, that waging war against every major power in the world (other than Japan) was a recipe for you to get thrown out of power and killed. He did send several highly idealistic divisions to fight the bolsheviks on the Easter front. From all accounts they were very brave, although not all of the divisions were "volunteers". When the war started turning sour he pulled them I believe. "Eventually, the Allies began to pressure Franco to withdraw his troops. Franco initiated negotiations in the spring of 1943 and gave an order of withdrawal on October 10. Some Spanish soldiers refused to return."
Here is wiki's sum of it. Pretty interesting sidenote to the whole war
Although Generalísimo Francisco Franco did not enter the war on the side of Nazi Germany, he let volunteers join the German Army (Wehrmacht), however only on the condition they would exclusively fight against Bolshevism at the Eastern Front. In this manner, he could maintain Spanish neutrality while simultaneously repaying Hitler for his support during the Spanish Civil War (see Condor Legion). Spanish foreign minister Ramón Serrano Súńer made the suggestion to raise volunteer corps, and at the commencement of Operation Barbarossa, Franco sent an official offer of help to Berlin.
Hitler approved the use of Spanish volunteers on June 24, 1941. Volunteers flocked to recruiting offices in all the metropolitan areas in Spain. Cadets from the officer training school in Zaragoza volunteered in particularly large numbers. Initially, the Spanish government was prepared to send about 4,000 men, but soon understood that there were more than enough volunteers to fill an entire division (18,104 men; 2,612 officers and 15,492 soldiers) - according to an estimate of the German ambassador, they could have formed 40 divisions.
Fifty percent of officers and NCOs were professional soldiers, many of them being veterans of the civil war. Many others were members of the Falange (the Spanish fascist party). Others, like Luis García Berlanga (who later became a well-known cinema director), despite their moderately left-wing political standing, volunteered in order to help their relatives in Franco's prisons. A high percentage of volunteers also joined seeking revenge because some of their relatives were assassinated by Stalinist forces supporting the Republicans during the Spanish civil war. But many of them, badly so called volunteers, were recruited under a certain pressure.