https://www.youtube.com/watch?v=bhyYgnhhKFw
too long; didn't watch:
The royal family likely contributes quite significantly to the popularity of the UK tourism industry, which brings in FAR more money to the country than the institution costs to maintain, even considering all the royal salaries to pay, the palaces to maintain, public events to produce, security, etc.
They also lease out a great amount of land to the country - to the wide benefit of the entire populace - for pennies of what it would cost the nation to purchase such land and resources outright.