Koko, the thoughtful gorilla who captivated the world through her ability to use sign language and revealed an empathetic side to great apes, has died. She was 46.

The western lowland gorilla passed away in her sleep Tuesday morning at the Gorilla Foundation’s preserve in California’s Santa Cruz mountains, the foundation said.

“Koko touched the lives of millions as an ambassador for all gorillas and an icon for interspecies communication and empathy,” the foundation said on its website. “She was beloved and will be deeply missed.”

Koko was believed to have had an IQ of between 75 and 95 and could sign more than 1,000 words. The average IQ of a human is around 90 to 110. She also understood spoken English.

Born at the San Francisco Zoo, the gentle, nearly 300-pound ape began learning sign language as a baby in 1974 from Dr. Francine “Penny” Patterson as part of a Stanford University project.

She spent her entire life in captivity and became a celebrity in her own right.

Her remarkable ability to sign landed her on the cover of National Geographic twice — in 1978, in a photo she took of herself in a mirror, and again in 1985, with an image of her mourning the death of one of her pet kittens.

Throughout her life, Koko adopted several felines, using sign language to give them names like All Ball, Lipstick and Smoky. She was gifted a box of kittens on her 44th birthday.

Her love of animals spawned the children’s book “Koko’s Kitten” and her own branded line of toys.

In 2012, she stunned scientists by playing wind instruments, including the recorder, harmonica and party-favor whistles — an ability that showed primates can learn to control their breathing, NPR reported. Controlled breathing was believed to be beyond their ability.

Koko met a slew of celebrities over the years, like Betty White, Leonardo DiCaprio and the late Robin Williams — who shared hugs and laughs with the gorilla during their 2001 encounter.

“Her impact has been profound and what she has taught us about the emotional capacity of gorillas and their cognitive abilities will continue to shape the world,” the foundation said.