As far as I'm aware it is the King or Queen (or the Regent on behalf of the King/Queen) who decides the people assigned to the Kingsguard, who are supposed to be a selection of the greatest swordsmen in Westeros. However, it's highly improbable that the monarch would be able to see a significant number of swordsmen in action in order to be able to make an informed decision as to who is suitable for the role.
It's possible that trusted advisers, such as those on the small council or others within the Kingsguard, could offer advice and nominate those who may be worthy of the position when an opening becomes available. But again, I can't imagine they manage to travel enough to meet potential candidates.
There is always word of mouth as to the ability of swordsmen, but that can sometimes be unreliable. And there are tourneys in which knights can show off their abilities, but again it doesn't seem like that would make a consistent selection method, as a holding a new tourney every time a member of the Kingsguard dies would be expensive.
So is the pool of candidates smaller than the reputed "greatest swordsmen in the land"? Is it instead just people close to the King/Queen who manage to work their way up politically in order to garner favor with the royal family, ensuring their selection when an opportunity presents itself?
Or is there some sort of trial that candidates go through to prove they are worthy? Would those wanting the position have to approach the King/Queen personally and prove themselves fit for the job?
Prior to the events of the books, I feel there really isn't very much depth as to how previous members of the Kingsguard who were famously skilled with a sword (Barristan Selmy, Arthur Dayne etc.) were selected in the first place.
Since then, the majority of the selections have been done by Cersei, who has filled the ranks of the Kingsguard mainly with people she trusts and who she knows will not betray the king in this particularly volatile political climate, and who will do as she commands, as opposed to people who are actually particularly skilled swordsmen.
So is/was there any kind of standardized selection process, or would the King simply select new members at whim for any reason whatsoever?