Do you know which rental car company you'll be using? The big clusters of all rental companies right next to transit hubs tend to be at airports.
Getting all the way from Sacramento or Davis into San Francisco will involve making a transfer or two and might include taxi, train, Bart or bus depending on how you do it.
The Oakland airport isn't bad, but you will need to take the airbart bus from the airport to the Bart station. As I recall there is also a shuttle from the rental agencies to the main airport where airbart has its stop.
There are an Avis and an Enterprise rental agency near the downtown Berkeley Bart station if you're using one of those agencies. Those may be a little more direct than Oakland airport for getting on Bart.
Bart is probably your fastest direct transit connection from the other side of the bay directly into San Francisco, but there are not that many car rental company locations right near a Bart station that I'm aware of.