Last year, about 60,000 school children from the region visited Levi’s Stadium. The 49ers also funded free flag football leagues for 3,000 boys and girls that were hosted by the Boys & Girls Club, Police Athletic League and city recreational programs there. Children who play in these leagues all receive a Niners reversible jersey. The team will also run one-time football clinics, often with 49ers, in the East Bay. The team intends to triple that number next season by working with those organizations in the East Bay.

“We want kids to be 49ers fans, but it’s not like we want someone not to be a Raiders fan,” said Hannah Gordon, the team’s chief administrative officer.

Sports leagues have tried in the past to create boundaries so that neighboring teams do not encroach on each other’s markets. In the N.F.L., a team’s territory was a 75-mile radius from its home city. Because San Francisco and Oakland are just 10 miles apart, the 49ers and Raiders have informally stayed out of their each other’s cities — no billboards, for instance.

But the growth of social media has made lines on a map obsolete, and now the Raiders are gone altogether.

Winning the hearts of abandoned fans is not easy. The Mets were created in 1962 five years after the Brooklyn Dodgers and New York Giants moved to California. The Chargers, who abandoned San Diego three seasons ago, are struggling to gain traction in Los Angeles.