Seems like Barney Stinson is a man of many talents. In addition to being a famous television and Broadway actor, he has enough time for some side magic-action. Neil Patrick Harris is currently serving a two year term as president of the Academy of Magical Arts.
They're headquartered at the Magic Castle, which is a private clubhouse for the organization. They currently have over 2500 members and even have an awards ceremony that NPH has hosted before. To be a member, you have to be active in magic either as a career or hobby, and audition in front of a committee. This means that at some point, someone got to see Neil Patrick Harris perform magic for them!