Because the Spanish Empire was practically dissolved. Spain was paid $20 million for the new colonies by the United States. Spain agreed to hand over colonies like Cuba, Puerto Rico, Guam, the Philippines and the parts of the West Indies that they controlled to the United States. The war also affected Spain culturally.