Watch How German Shepherd Barks at Owners v. Strangers—'Personality Change'

A German shepherd dog has captured the hearts of millions after she showed off her broad vocal range—and range of personalities—in a clip which has gone viral on TikTok.

In a video shared to her owner's account, @alaska_germanshepherd, on July 8, the pup can first be heard yapping in a high-pitched tone to the camera.

The playful barks then come to a sudden stop as her ears twitch, and another dog begins barking outside.

Clearly having heard someone walking by, she trots outside, her voice instantly becoming deeper and sounding off a warning, barking at the passerby.

Her owner wrote on the video: "How she barks at us vs how she barks at strangers."

And they added in the caption: "The personality change."

@alaska_germanshepherd

the personality change #gsd #dogsoftiktok #funnyvideos #funnydogs #germanshepherd

♬ Funny - Gold-Tiger

A 2018 article from the American Kennel Club notes that dogs change the pitch, the amount, and the space between their barks to alter the meaning of the vocalization.

The lower the bark, the more serious the dog is acting, the article explains, using a bark while playing versus a bark to ward off strangers to illustrate the point. A bark welcoming their owner home, for example, will be a far higher pitch than a bark warning off a stranger coming up the driveway.

TikTok users were fascinated by the video and personality change, with the clip having racked up close to 20 million views and over 4.2 million likes in a matter of days.

And while there is behavioral science behind the barks, one user summed it up: "Regular voice vs customer service voice."

Another pointed out: "So you're telling me our dogs talk to us in a baby voice."

And one delighted user wrote: "She had such a girly bark omggggg so cute."

German shepherds are not noted as a particularly vocal dog, and do not appear on Purina's list of the most vocal dog breeds, though much smaller dogs such as the Chihuahua, Maltese, and Russell terrier are known for making themselves heard.

However, they are known to be a good breed of guard dog, with the American Kennel Club noting their "vigilant" and protective nature.

The breed is described as loyal, courageous and confident, and will put their life on the line in defense of their loved ones.

The dog was filmed barking playfully at her owners. She instantly went into guard-dog mode when she heard something outside. The dog was filmed barking playfully at her owners. She instantly went into guard-dog mode when she heard something outside. TikTok @alaska_germanshepherd

But, like all dogs, they can also be goofy playmates, and this dog's viral story comes after another GSD found online fame for testing his skills at a skate park.

In a video by @georgialou1se on TikTok, Gary the German shepherd attempts to walk up a ramp before falling on his face, and the second attempt doesn't fare much better.

His owner joked on the clip that he "is definitely not a sk8r boi."

Do you have funny and adorable videos or pictures of your pet you want to share? Send them to life@newsweek.com with some details about your best friend and they could appear in our Pet of the Week lineup.