The worst thing you can do is send a generic query to every agent you find online or - worse - cold-email someone who isn't actively seeking submissions. You'll just get deleted. And don't fall for those "agent matching services" that cost money; they're mostly garbage. The submission guidelines exist because agents actually do want to find new work this way, but you have to follow the rules they set out.
The practical approach is to get specific. Look up agents on sites like Publishers Marketplace or MSWL (Manuscript Wish List), where agents literally post what they're looking for. Read their recent book deals to see if they've sold stuff similar to yours. Then craft a query letter tailored to that specific agent - mention one of their recent client books and explain why your manuscript fits their list. This takes time but it works because you're showing you did your homework, not asking them to guess whether they want your book.
Here's the thing most people skip: attend writing conferences or book events in your area. You don't need industry connections to show up, and sometimes agents hold pitch sessions where you get ten minutes face-to-face. That's gold. Even just chatting with other writers at these events helps you understand what agents are actually looking for and keeps you motivated through the rejection streak. I know the direct query method sounds daunting, but thousands of debut authors have gotten representation exactly this way. It's slow and frustrating, but it's not luck - it's just persistence and following the process that exists for people without connections.