England or Britain is a tiny country. Yet it managed to maintain a vast colonial empire for centuries. That must have been an extremely expensive endeavor. Maintaining, training all the armies, navies and running all the thousands of bureacracies across the globe. All the while the tax base was very little given that most of the colonized people were poor and there were very few rich people in Britain paying taxes.
So how did Britain finance all these large expenditures for maintaining its colonial empire?
The simplest and most accurate answer is that the colonies paid for themselves - and paid handsomely at that. For European Powers, the costs of maintaining colonial rule were tiny compared to the benefits.
The classic example is India. British colonial rule in India was enormously beneficial for the economy of Great Britain, despite the vast distances between the two countries.
This quote from an East India Stock holders meeting in 1840 gives an idea of the simple tax benefits of Indian rule:
Possessed of a population four times greater than that of the United Kingdom of all the rest of the British empire in all parts of the world—defraying from its own resources the whole charge of its civil Government and of its military defence—subject to the rule of British-born subjects, in all the higher and more lucrative and honourable offices of the State, India is further required to transmit annually to this country, without any return except in the small value of military stores, a sum amounting to between two or three millions sterling, of which by far the largest portion must necessarily be transmitted in each and every year without regard to the cost at which such transmission may be made, or to the derangement of the ordinary calculations of merchants which it may occasion.
The Raj didn't just extract tax and raw resources from the Indian sub-continent either - they radically retooled the Indian economy to suit their own needs.
The Permanent Settlement of 1793 was an early example. It created a new landlord class - destroying the old zamindar class of landlords in the process - whose right to their lands was entirely dependent on regular payment of taxes to the East India Company and later the Raj, with 89% of taxes going to the British. This had consequences for Indian society that reached well into the twentieth century.
By destroying the traditional Moghul aristocracy and introducing a policy of tax-free imports from Britain and heavily taxed exports from India, the British helped transform the economy from an exporter of manufactured goods to an importer of piece-goods and exporter of raw materials. The previously thriving textile industry was crushed under these tariffs, combined with a flood of machine-produced textiles from factories in Britain. The export of cheap raw materials was a major boon for the industrializing cities of Great Britain. The vast network of railways built by the British meant local landlords would force their tenants to grow cash crops, leading to famine in many places and an actual increase in number of Indians farming over the course of colonial rule. The rail companies were also exclusively staffed by whites, who repatriated most of their earnings home.
According to the economic historian Angus Maddison, early 18th century India had 22.6% of global GDP. This had dropped to 4% by 1947. Many factors come into play here, industrialization being foremost, but what is undisputed is that Great Britain extracted resources from India on a colossal scale. What the Indian nationalist Dadabhai Naroji called "The Drain of Wealth" was very real and colonial rule extremely lucrative. Even though the tax-base in Britain was quite low and their military expenditures quite high, the overall benefits of colonialism more than covered the costs.