A 3-year-old male Shiba Inu had his head stuck between two boulders in Lakeside on Thursday afternoon, according to San Diego Animal Control.
The dog, Toby, became trapped just before 2 p.m. at 8522 East County Dr.
Toby reportedly chased a squirrel into a rock pile that forms a waterfall when his head became stuck.
Animal Control and the fire department reported to the scene. A vet technician calmed the animal down with a sedative, and then freed the animal by using a mixture of a cream and olive oil.
"After we were able to administer those drugs and put a little lubricant around the head of the dog, were were able to gradually get that area out and safely extract the animal without having to move some large boulders," said David Johnson from San Diego Animal Control.
Toby's owners have taken him to the animal hospital to examine any possible injuries.
Keep up to date on breaking news: Download our improved iPhone app, follow us on Twitter @nbcsandiego, fan us on Facebook, sign up for our breaking news e-mail alerts or text SDBREAKING to 622339 to receive text messages for local breaking news. (For more info, text HELP. To end, text STOP. Message and data rates may apply.)