Yes, noise-cancelling headphones can block out dog barking, but they may not be 100% effective. The level of noise-cancellation will depend on the quality of the headphones, and how well they fit your ears.