The legendary Mary Tyler Moore Show actress confirmed her illness in an interview published in the next issue of People.
Harper learned on January 15 that she has the rare condition leptomeningeal carcinomatosis, which takes place when cancer cells spread into the membrane surrounding the brain.
The 73-year-old revealed that her doctors have told her she may have only three months left to live, but she added that she is trying to focus on the present.
"I don't think of dying," she said. "I think of being here now."
Harper is probably best known for her role as Rhoda Morgenstern in The Mary Tyler Moore Show and its spinoff Rhoda, though she also appeared in her own show Valerie and has had guest spots in episodes of Sex and the City, Desperate Housewives, Drop Dead Diva and, most recently, The Simpsons.