Vehicle electrification can significantly decarbonize the transportation sector. Widespread adoption of electric vehicles (EVs) depends on their cost relative to conventional alternatives. Here we compare the total cost of ownership (TCO) of gasoline, hybrid, and electric vehicles. First, we review previous TCO studies, showing that the components (e.g., purchase price, financing, taxes, fees, insurance, refueling, maintenance, repair, and home charging equipment for EVs), parameters (e.g., vehicle miles traveled, discount rate, and lifetime), and methods differ greatly. Then, we develop a comprehensive TCO model comparing across five vehicle classes, three powertrains, and three EV ranges. Using 14 cities in the United States and multiple charging scenarios, we investigate TCO variability based on location and use pattern. We include adjustments for local gasoline prices, electricity rate plans, home charging access, and the impact of local temperatures and drive cycles on fuel economy, among other factors. We show that for a 300‐mile range midsize electric SUV, TCO varies by $52,000, or nearly 40%, across locations. Home charging access reduces the lifetime cost by approximately $10,000 on average, and up to $26,000. EVs are more competitive in cities with high gasoline prices, low electricity prices, moderate climates, and direct purchase incentives, and for users with home charging access, time‐of‐use electricity pricing, and high annual mileage. In general, we find that small and low‐range EVs are less expensive than gasoline vehicles. Larger, long‐range EVs are currently more expensive than their gasoline counterparts. And midsize EVs can reach cost parity in some cities if incentives are applied.