If I were an author looking for an agent, here is what I would do.
I would not just send a query and hope for the best. Agents are overwhelmed with queries and they don’t always get read. This is what I would do instead.
The best way is through a referral. That means you have to know someone who is represented by a good agent. Join a good writers group that includes published authors and get to know the other members. Shmooze around. Talk to people. Go to a writers conference. Get a sense of who you might want. Do this with good faith and an open spirit. You want to genuinely get to know people and form bonds. Don’t just do this to pick someone’s brain. You are looking to join a community, not to use people. Successful authors are often open to helping new writers. Make friends wisely. Don’t push it, but keep up the contacts.
The next step is the hardest. You have to be ready and you have to be good. No one wants to recommend shoddy work to their agent. They will have an idea of what their agent represents, and of course you can check out the websites of just about every agent and get a sense of who they are, what they do, and how they operate. There are plenty of good agencies, but you only need one. Before you approach anyone, you have to be positive that what you have to offer is the right stuff. No matter how much you love it, get other opinions from people who would know. That means any publishing professional, your published author friends, or freelance editors. It does not mean your mother, your spouse, your best friend, or your dog. They are not objective and they don’t know anything about the business.
Finally, I would take the big step and ask someone if they would be willing to refer me to their agent. Do this only after you are very sure you have accomplished all of the above. You may get a hedgy answer for various reasons. Or you may get an enthusiastic yes. There is only one way to find out. Ask politely, don’t push, and be ready to keep trying.
Best of luck with this process. I have taken on more new clients through referrals than through any other method. So I can assure you that this does work. Learn how to network, be brutally honest with yourself, and keep your eyes on the goal.