In a home environment, they can be discouraged by using a weight-sensitive feeder. Some oif these “squirrel-resistant” birdfeeders can adjust. So when anything heavier than a few ounces sits in front of a seed port, the port closes. (Most “good” birds weigh less than 2 ounces.) Often, the feeder’s “tipping point” can be adjusted if, for instance, you like Blue Jays – which weigh about 5 or 6 ounces, but don’t want Grackles, which are about 8 ounces.