Get the dog out of the yard. For the next month the yard is a place it goes with you, on a line, and comes back in from. That's the short version, and most of what we'd say if you only had a minute.
The longer version is that nothing you do in a training session is going to stack up against what the dog does on its own at the fence while you're at work. If it's out there for a few hours and the neighbor's beagle is out there for the same few hours, that's the dog's real training schedule, and you're not on it.
So the first job is to end the practice. Then the training has a chance.
Picture the fence from about knee height. There's a barrier the dog can't get through. On the far side is the beagle, or the landscaper with the leaf blower, or the woman who walks a Great Dane past at the same time every evening. Your dog can hear all of it and smell most of it. It can't reach any of it, and it can't leave, because the yard ends at the fence in every direction. So it runs the line and barks. If there's a dog over there, that dog runs its line and barks back. Then the beagle gets called in, or the leaf blower moves to the next house, and as far as your dog can tell, the barking is what made that happen. Tomorrow it starts sooner. We see this often with apartment dogs too, where hallway and neighbor noise play the fence's role, so read about what causes apartment dog barking.
That's the loop. We've met dogs that have been in it since they were six months old and are now eight.
Stop the practice
Starting today, the dog doesn't go in the yard alone. Not for a potty break, not while you unload groceries. You go out too, and the dog is on a long line, 15 or 20 feet, clipped to a harness. You don't have to hold it the whole time. Let it drag. The point is you can step on it and bring the dog in without a chase.
Plan on this for at least three or four weeks. People hear that and think we're being dramatic. We're not. The dog has a habit and the habit has a location, and the location is fifteen steps from your back door.
Second, block the view. This matters more than most people expect. Chain link is the worst case, because the dog sees everything and can press its face right into the mesh. Privacy slats, reed screening from a hardware store, or a few sheets of plywood zip-tied to the section where the barking happens will all do. You don't need the whole fence, just the stretch the dog patrols. Walk the line and you'll find it, usually worn down to dirt. When the barking starts up away from the fence too, stopping a dog from barking outside takes other steps.
Check the bottom of the fence too. A gap of a couple of inches is enough for two dogs to sniff and snap at each other, and that's where a lot of the heat comes from. Landscape timbers or a strip of hardware cloth along the base fixes it.
If the fence is shared, tell the neighbor what you're doing. Most are relieved. If they have the barking dog on their side, ask if they'd be willing to stagger yard times with you for a few weeks. You take mornings, they take afternoons. That alone cuts the problem in half for both of you, and it costs nothing.
Teach the fence
Once the dog isn't rehearsing, you teach it what to do instead. Two things.
The first is a recall away from the fence, and you build it when nothing is happening. Dog's in the yard on the long line, sniffing. You say its name and a word, "here" or whatever you use, and when it turns, you back up a few steps and feed it something real at your feet. Cooked chicken, cheese, not kibble. Ten reps a session, two sessions a day, for a week before you ever try it with the neighbor's dog out.
Then you release the dog with a word and let it go back to what it was doing. That part matters. If every recall ends the fun, the dog starts doing the math.
The second thing is harder to describe and easier to do. You want the dog to notice the trigger and look at you instead of launching. Set it up: you're out there with the dog on the line, and you're standing well back from the fence, 25 or 30 feet. The neighbor's dog comes out. Your dog's ears go up. Before it barks, you say "yes" and put a piece of chicken on the ground right in front of it. It eats, looks back at the fence, "yes," chicken. Five or six of those, then you call the dog inside and you're done.
If it barks anyway, you're too close. Step on the line, walk the dog inside without saying anything, try again tomorrow from farther back. Don't scold it. It's not doing anything wrong, it's just over its limit.
Over a couple of weeks you move closer in five-foot steps. You'll know you've moved too fast when the dog stops being able to eat. A dog that won't take chicken is a dog that's too close.
No bark collars, no shaking cans of pennies, no spraying the dog with the hose. We don't use them and we won't walk you through them.
One case where the training won't be enough: if your dog has grabbed a person's hand through the fence, or has turned and bitten you when you pulled it off the fence line, work with a certified professional through IAABC or CCPDT before you do any of the setups above. If the barking is new and the dog is older and nothing outside has changed, a vet visit is worth it before you assume it's behavior.
The neighbor's dog
Sometimes the real fix is on the other side of the fence, and you can't control that. What you can do is make your dog the one that quits first. Barking at a fence takes two. When one dog consistently gets called off and fed, and the other is left barking at plywood, the other dog's owner usually notices, and about half the time they come over and ask what you did.
Some dogs also bark at the fence at night, at raccoons or at whatever the dog across the street is barking at. That's a different schedule and a slightly different fix, and our post on stopping a dog barking at night covers it.
If the same dog also goes off at the front door, the setups are nearly identical, and our general post on how to stop a dog barking walks through the version for inside the house. You can run the setups with our doorbell trainer if you don't have a helper.
Expect the fence to take longer than the door. The yard is big and the dog has had the run of it. Four to six weeks of not leaving the dog out alone, with the screening up and the recall practiced daily, is where we'd tell you to start measuring. If it's better at six weeks, keep going. If it's exactly the same, something in the setup is still letting the dog practice, and usually it's the unsupervised ten minutes someone forgot to count.
If you want the door version of this laid out day by day, our guide Calm at the Door in 21 Days does that, and the fence work follows the same shape.

Calm at the Door in 21 Days
The 21-day plan for dogs who bark at the doorbell, the window and every visitor. 10 minutes a day, reward-based, 6 printable tools.
See the plan →Not sure yet? Take the free 2-minute quiz
Educational content from the CalmDoor team. Not veterinary or behavioral advice for your specific dog. If your dog has bitten, or behavior changed suddenly, see your veterinarian and a certified professional.











