In the Rio Cup, the second stage of the Rio de Janeiro state tournament, Flamengo beat Friburguense 1-0 despite the absence of Ronaldinho and Vagner Love, while Botafogo defeated Vasco da Gama 3-1 with a hat trick by Fellype Gabriel.
Former Brazil striker Luis Fabiano also scored for Sao Paulo at the Morumbi stadium, while Neymar scored one of Santos' goals.
Sao Paulo played a man down from the 54th because defender Rodrigo Caio was sent off with a second yellow card for a hard foul.
Before the match, fan from both clubs fought each other outside the stadium, but police didn't report any serious injuries.
The 19-year-old Lucas netted the winner in the 87th by hitting an open net after a shot by teammate Cortes rebounded off the post.
Midfielder Casemiro opened the scoring for Sao Paulo with a long-range shot in the ninth, and defender Edu Dracena equalized for Santos from close range in the 52nd. Luis Fabiano put Sao Paulo ahead again by converting a penalty in the 65th, and Neymar pulled defending champion Santos even by dribbling the ball past the goalkeeper before finding the net in the 77th.
The victory gives Sao Paulo 31 points from 14 matches, one less than Luiz Felipe Scolari's Palmeiras, which defeated Ponte Preta 2-1 at the Pacaembu stadium on Saturday to extend its unbeaten streak to 20 matches.
Corinthians dropped to third after its second-stringers needed two late goals to draw 3-3 with last-placed Comercial. Gilsinho scored in the 90th and Ramon three minutes into second-half injury time to give Corinthians the draw in Ribeirao Preto. Recently promoted Comercial hasn't won in 10 matches.
Corinthians' regular starters were rested because of the team's match in the Copa Libertadores later this week.
Santos is fourth in the standings. The top-eight will advance to the playoff round.
In Rio, Flamengo also rested some starters in its 1-0 win over Friburguense behind a goal by 2006 World Cup veteran midfielder Kleberson.
Striker Fellype Gabriel scored in the 34th, 37th and 72nd minutes to give Botafogo a 3-1 win over Vasco da Gama. Fellipe Bastos scored Vasco's lone goal in the 47th.
Fluminense, also in the Copa Libertadores, used second-stringers in its 3-1 win over Macae on Saturday. Fluminense has already secured a shot at the state title because it won the Guanabara Cup, the competition's first stage.
The Brazilian football season does not follow the European calendar and starts at the beginning of the year with regional championships in the 26 states and the federal district. The Brazilian league will start in May and finish in December.