There were two driving forces of imperialism at the end of the nineteenth century. The first was the Industrial Revolution. While much of Europe industrialized at an exponential pace the nations needed raw materials to fuel their factories. Many European nations began to see depletion in their own resources or didn't have certain vital resources. As a result they sought them out in new places. An additional effect of imperialism towards industrialization was that in addition to gaining new resources, they also gained new markets with which they could conduct trade.
Nationalism also played a role in the empire building of the late nineteenth century. Countries around Europe looked to prove that they were ready to dominate the politics of the continent, and having a large empire was a source of national pride and strength. While there were some intense struggles to gain control of certain areas, the overriding factor in the success Europeans had in the creation of their empires was their advanced military technology. While some areas lacked the political cohesion to effectively mount a defense, the natives had little chance to prevail against the firepower of their invaders.