If you say because they had the best navy - why
1. Having a strong navy is very important in your ability to project power across the globe and the British had or had close to a navy as powerful as the next two most powerful navies combined . This allowed them to project power far better than any other power at the time
2. The UK is an island nation so for any country to successfully invade the UK they had to first defeat the royal navy and since no other navy came close , this meant the UK was close to impossible to invade . This meant they could focus more of their resources and energy in expanding and maintaining their empire while other European nations and to be constantly on guard for a potential invasion
I was asking more why they had a strong navy... being an island can't be the only reason.
They were wealthy and industrialized before anywhere else in the world. "In 1875, Britain accounted for 47% of world production of pig iron and almost 40% of steel." It's not exactly a great mystery.