Beneath the glittering crown and fine robes, therein is a head of state.
A king/queen is a head of government, the ruler of their particular country/empire.
The welfare of the people in that country (and by implication the whole country) is the responsibility of the monarch.
Even where a monarch's 'official' power is limited - eg they are a constitutional monarch - there is so much that monarch can still do for their people. LEAD BY EXAMPLE for instance.
This is what makes a truly great king/queen - a monarch who understands this responsibility, takes it to heart and acts accordingly.
That's why I nominate George IV of England as a truly great king.
Forget this monarch's 'reputation'. George IV took 'street kids' into his palaces and ensured they were protected, fed and educated. He liked to do housework to relax (!), he knew that "one could always earn a living doing other people's chores" and so he used his palaces as training academies. His wards (as they were called) were taught how to do housework; it became generally accepted in England that if you wanted a reliable butler or maid "hire one of George's wards."
George IV also insisted that any beggar who came to one of his palaces asking for alms should be given alms.
George IV fought his own parliament to try to abolish slavery. When this failed, he used his own money to start a homeland for slaves freed from slaver ships. Freed because George IV ordered his navy to stop slavers on the coast of Africa and free the captives.
George IV was known to his friends as "the one who walks in when the others walk out." His courage was undisputed. For instance, though he could not swim he risked drowning to rescue a commoner from drowning. He was generous with his time and resources, and made equally generous allowance for human failings - though he expected honesty and uprightness.
All this makes George IV a truly great king.