Bred as herding dogs, German shepherds are high-energy dogs who like to talk. Barking was a tactic for keeping sheep moving along, and it's a trait the breed hasn't given up over the generations. When yours keeps mouthing off nonstop, take charge, train him and provide diversions to help him kick the habit.
Your Position: Alpha
German shepherds are intelligent dogs with a strong sense of pack hierarchy. Establishing yourself as the alpha dog means your pooch is going to respect you and your authority. Direct your dog with confidence, and act like a leader -- don't let him take toys away from you or win at tug-of-war until the ground rules are firmly established. Begging or cajoling won't work with German shepherds. Instead, tell him what to do in a firm voice to gain authority. Once you've established your position in the household, he'll be more likely to stop barking when instructed to.
Your pooch was bred to chase sheep all day, which means he has energy to burn. Ensuring he has plenty of exercise daily should reduce his barking. A tired dog won't have the energy to bark for no reason, and the daily stimulation, if you take him outside your yard, will alleviate boredom barking. German shepherds are immensely trainable, so try your hand at throwing him a flying disk, teaching him tricks or running a backyard obstacle course in addition to daily walks and trips to the dog park.
To train Kaiser to stop barking on command, first teach him to speak on command. This helps him learn the appropriate times to bark. Wait until he starts barking, then say, "Speak." When he continues barking, give him a treat as a reward. Continue this process until he starts barking after you say the command rather than before you say the command. When that skill is firmly ingrained, start working on the "Quiet" command. As he's barking, say, "Quiet," in a firm but low voice -- there's no use trying to out-yell a barking dog. Keep saying it over and over until he stops barking, then give him a treat. When you think he has the idea, instigate his barking with the "Speak" command and stop it with the "Quiet" command, giving treats each time he follows your instruction. The next time he's barking at the mailman, tell him the "Quiet" command so you don't have to chase your mail down the street.
Boredom and separation anxiety are common reasons your pup barks during the night or when you're not home. Keep him occupied by filling his world with toys. German shepherds are smart enough to enjoy puzzle toys, which they must flip around until a treat falls out. Yours might enjoy toys that light up or make noise as he plays with them.