San Francisco's Time Zone Isn't as Simple as You Think
The Pacific Time Zone runs on two different offsets depending on the calendar month. San Francisco sits in it, which means the city switches between UTC-8 during standard time and UTC-7 during daylight saving time. That switch happens around the second Sunday in March and again on the first Sunday in November. Most people who live there just accept it. Everyone else deals with the confusion. I used to book conference calls with West Coast contacts without thinking about it much. Then I missed an entire product launch briefing because I scheduled for 9 AM PT in what I assumed was standard time. It was mid-April. The meeting actually started at 10 AM my time. I've been using IANA timezone identifiers ever since instead of guessing.
What Is The Time In Sfo Breaking Down The Confusion Around San Francisco Time Zones
The Practical Breakdown
Pacific Standard Time (PST) is UTC-8. Pacific Daylight Time (PDT) is UTC-7. San Francisco observes both. The city doesn't pick one and stick with it year-round. The switch is mandated by federal law in the United States, which means every city in the Pacific zone follows the same schedule regardless of local preferences. Here is the actual schedule that applies to San Francisco: daylight saving time starts at 2 AM local time on the second Sunday of March. Clocks jump forward one hour. Standard time resumes at 2 AM local time on the first Sunday of November. Clocks go back one hour. This has been the pattern since the Uniform Time Act of 1966, though Congress changed the start and end dates in 2007 under the Energy Policy Act. Before 2007, DST began on the first Sunday in April and ended on the last Sunday in October. That historical detail matters if you are parsing old records or legacy systems that store timestamps with fixed rules rather than current IANA database entries. An application written in 2005 might calculate past dates incorrectly because it assumes the old DST transition schedule.
How to Actually Get the Right Time
Don't try to calculate this manually. The offset changes twice a year and the exact dates shift slightly depending on how the calendar falls. Here is what works: Use the IANA timezone database. The identifier for San Francisco is America/Los_Angeles. This covers the entire Pacific zone, not just the city itself. When you reference this identifier in any modern programming language or tool, the system pulls the current rules from the database and applies them correctly including all historical edge cases. Python example:
Get the Full Details

from datetime import datetime from zoneinfo import ZoneInfo sf_time = datetime.now(ZoneInfo("America/Los_Angeles")) print(sf_time.isoformat()) This gives you the correct current time in San Francisco with no manual offset math. The zoneinfo module handles the DST transitions internally by reading the tz database shipped with your Python installation. JavaScript example:
const sfTime = new Date().toLocaleString("en-US", {timeZone: "America/Los_Angeles"}); console.log(sfTime); The toLocaleString approach with an explicit timeZone parameter is the most reliable method in JavaScript because it delegates the calculation to the runtime's underlying ICU data rather than trying to implement timezone logic yourself.
The Edge Case That Costs People Money
I once had a batch job that processed payment reconciliation for a fintech client. It ran at 3 AM every day in San Francisco time and wrote results to a database with UTC timestamps. For two years it worked fine. Then the server got migrated to a new environment where the operating system timezone was set to UTC but the application code still read the system clock directly instead of using the IANA database. Between November and March, the job wrote timestamps that were off by one hour. We caught it when transaction timestamps didn't match bank settlement records. The fix was adding TZ=America/Los_Angeles to the environment variables and switching the application to query DateTime.Now.InZone(ZoneInfo.Create("America/Los_Angeles")) instead of relying on the OS clock. This kind of failure doesn't show up during DST. It only appears during the six months when PST is active, which is why it went unnoticed for a while. The system appeared correct half the year and wrong the other half.
Common Pitfalls That Keep Coming Up
AWS Lambda functions. When you deploy a Lambda without specifying a timezone, it defaults to UTC. If your function is supposed to process data based on San Francisco business hours, it will run on the wrong schedule. Set the environment variable TZ to America/Los_Angeles and make sure your runtime version includes the tz database. Older Node.js runtimes before 16 didn't always ship with complete IANA data. Scheduling tools that store offsets instead of zones. Some calendar applications let users pick "UTC-8" instead of "Pacific Time." That looks correct until DST starts, then the app is stuck with the wrong offset because it stored a fixed number rather than a rule-based timezone. Always prefer zone names over raw offsets when configuring anything that needs to handle daylight saving transitions. Database functions that don't respect timezone databases. MySQL's CONVERT_TZ function requires timezone tables to be populated. If you're running MySQL without loading the official timezone tables, conversions will silently fail or return incorrect results. PostgreSQL handles this better by referencing the system's tzdata directly. SQLite has no native timezone support, which means you have to handle it in your application code before inserting or after querying.
When This Approach Falls Apart
The IANA database approach is reliable for most use cases, but it has real limitations. Legacy systems that store dates as simple integer offsets without timezone context cannot be fixed by changing application code. You would need to rewrite the storage layer or add a translation table. This is common in older ERP systems and some industrial control platforms where timestamps were stored as "hours from UTC" with no zone identifier. Another hard case is cross-database joins where one system uses IANA zones and another uses fixed offsets. If you're joining a modern application database with a legacy mainframe export, the mismatch can produce incorrect results even when both sides think they are storing the same thing. The workaround is usually to normalize everything to UTC at the ETL layer before any joining happens. There is also the question of political changes. Territories occasionally change their timezone rules without warning. While San Francisco itself is stable, if you build a system that needs to handle timezone data globally, you should plan for the possibility that your tz database version becomes outdated. Set up periodic updates or pin your system to a specific database version and test after upgrades.