Maybe you have noticed a worldwide event this past year that temporarily impedes many of the activities people moved to SF and NYC to enjoy?
But anecdotally, most of the people I know who have left SF in the past several years were not especially wealthy (by SF standards at least) and have growing children. (This is a biased selection, since I spent lots of time at the playground.) The reasons for leaving included: rent-controlled apartment felt too small but moving to a market-rate bigger apartment was unaffordable; child care was too expensive compared to free help someplace else from grandparents / extended family; parents wanted their children to experience a suburban childhood similar to their own; parents didn't want to send their children to schools alongside poor children, but couldn't afford or didn't want to pay for private school, so preferred to move to a less economically diverse school district; parent's temporary city job finished, and the newly found job happened to be somewhere else.
The wealthier families I know have been less likely to move, since they either have a big enough home or can afford to move to one; can afford to pay for nannies etc., or can afford to have one parent stay home; can afford private school if they want; have more permanent jobs or an easier time finding a new job in the same area; ...