The phrase Spanish Republic at war refers to the Second Spanish Republic during the Civil War of 1936–1939. It represents the last stage in this war's history. The territory that remained under its control after the coup of July 1936—which was called the republican zone or the loyalist zone—gradually reduced as the rebel zone spread, until it was finally occupied in its entirety by the Francoist side (which had referred to the areas as the red zone throughout the civil war).
During this time, there were three consecutive governments: the one presided over by José Giral, from Republican Left, although during his short term (July–September 1936), real power was actually in the hands of the hundreds of committees that were created when the social revolution of 1936 broke out. The next government was presided over by Francisco Largo Caballero, the leader of the Spanish Socialist Workers' Party (PSOE) and the Unión General de Trabajadores (UGT), one of the two trade unions that had led the revolution. Finally, the third government was presided over by Juan Negrín, also from the PSOE, as a consequence of the fall of Largo Caballero's government after the events of May 1937. Negrín governed until early March 1939, when Colonel Segismundo Casado's coup took place, putting an end to the Republican resistance and giving way to the victory of the rebel faction led by General Francisco Franco.