WASHINGTON—Sandra Day O’Connor, the first woman appointed to the Supreme Court and its most influential justice for much of her tenure, announced Tuesday she has been diagnosed with dementia and is withdrawing from a post-retirement career that extended her influence from the classroom to the White House.

“As this condition has progressed, I am no longer able to participate in public life,” said Justice O’Connor in a statement released by the Supreme Court. “Since many people have asked about my current status and activities,...