Open a door or window in your home so that the squirrel has a route of escape. The University of Missouri recommends this as the squirrels will likely find the way out themselves.
Examine the outside of your home in search of holes or small entryways the squirrels may have used to get inside. Set wire or cage traps up over or near the holes to catch the squirrels as soon as they come out, if they don't exit the premises on their own. Setting a trap in your attic is also a good idea, as squirrels are often found making nests in attics.
Bait the traps with either peanut butter, apple slices, walnuts or peanuts to help draw the squirrels out of the wall. Once the squirrels smell the bait, they will begin searching for it.
Release the trapped squirrels at least 10 miles from your home to keep them from returning to your property. A park or similar wooded area is ideal. You should, however, consult with local authorities before you transport the squirrels, as some counties advise against translocation.
Take measures to prevent squirrels from entering your home and getting inside your walls in the future. This includes plugging up all holes, trimming back tree branches that are leaning toward or over your house, cleaning up brush piles and installing mesh screens over your chimney and attic fan. Include checking eaves for rotting wood where holes may have formed to your inspection, as this is another possible entry point for the squirrels.