Gascon informed his staff at an afternoon meeting before submitting a formal letter of resignation to San Francisco Mayor London Breed.
Gascon had previously signaled an interest in returning to Los Angeles, where he once served in the highest ranks of the city's police department, the Los Angeles Times reported.
He said in January that he would not seek a third term in the Bay Area, and in the following months he held several community meetings in the Los Angeles area to discuss criminal justice topics.
Our statement on the resignation of DA Gascon. pic.twitter.com/16WXWiFINo— San Francisco POA (@SanFranciscoPOA) October 4, 2019
Thanks for the warning SFPOA. Hey Gascon, stay away from LA. There is no welcome mat waiting for you. https://t.co/wdXy86S8KJ— Steve R. Gordon (@SGORDONLAPPL) October 4, 2019
If Gascon tries to unseat Los Angeles County District Attorney Jackie Lacey, the race could be the largest test yet of a nationwide push to elect progressive-minded law enforcement officials, the Times said.
Lacey is popular with law enforcement but has faced growing criticism from the left over several issues, notably her perceived reluctance to hold law enforcement officials accountable for accusations of misconduct and excessive force.
"Making our communities safer and more equitable remains my life's work, and I'm simply not ready to slow down and put public service behind me," Gascon wrote in Thursday's letter.
Lacey issued a statement on Gascon's apparent plans to challenge her:
"San Francisco's District Attorney has every right to quit his office and run for another one, and I welcome him into the race. I would put our office's record up against any D.A.'s office in the country. From creating a pathway for nonviolent offenders to get treated for mental illness instead of thrown in jail, to expunging thousands of nonviolent marijuana-related arrests, to aggressively prosecuting sex traffickers who exploit women and children, I'm proud our office has led on smart reforms that keep L.A. County residents safe."
First appointed in 2011, Gascon's second term would have finished at the end of the year.
The deadline for candidates to enter the Los Angeles race is in early December. Gascon's last day in office in San Francisco will be Oct. 18, according to the letter.
His chief of staff, Cristine Soto DeBerry, will take over as San Francisco's interim district attorney, according to the newspaper.