Fix guides

Supabase 401 PGRST303 "JWT issued at future": users sign in but every data request fails

Sign-in works, then the next database call returns 401 with PGRST303 "JWT issued at future", sometimes now and then, sometimes on every request. It is usually not your code. How to confirm it, the upgrade that fixes it, and what to do while you wait.

Free · no card

Paste your error. Get a free diagnosis by email.

Tell us what broke and we’ll email you a short diagnosis: the likely cause and what to try first. Usually within a day.

No passwords or secret keys, please. We only use your email to reply about this.

What you are seeing

Why it happens

  1. Supabase's troubleshooting guide says this error is normally caused by a known clock-skew validation bug in older PostgREST releases when they check newly minted JWTs. It is likely not an issue with your implementation.
  2. PostgREST fixed the sporadic PGRST303 errors in releases 14.18 (September 10, 2026) and 16.3 (September 11, 2026). Projects still running an older PostgREST can keep hitting it until they are upgraded.
  3. Reports on Supabase's GitHub this autumn match that pattern: a PostgREST 14.5 project failing right after a successful sign-in (October 30) and a project where every Data API request returned 401 from November 8 to 11 until a restart (issue #53283).
  4. Rarely it really is your tokens: a custom JWT minted on your own server with a clock that runs ahead, or third-party auth tokens with a bad iat. Supabase's guide points to its JWT docs if the error continues on PostgREST 14.18 or newer.

How to fix it

1. Confirm it is PGRST303 and not a bad key or RLS

# In DevTools > Network, open a failing /rest/v1/ request and read the body.
#   PGRST303 "JWT issued at future"  -> this guide
#   PGRST301 / "Invalid API key" / 42501 -> a different problem
# Or reproduce with a fresh session token from your app:
curl -s 'https://YOUR_PROJECT.supabase.co/rest/v1/your_table?select=id&limit=1' \
  -H 'apikey: YOUR_PUBLISHABLE_OR_ANON_KEY' \
  -H 'Authorization: Bearer USER_ACCESS_TOKEN'

2. Upgrade the project so PostgREST is 14.18 or newer

Supabase's fix: open the project in the Dashboard, go to Project Settings > Infrastructure, and under Project upgrades apply any available maintenance or infrastructure upgrade. That updates PostgREST. Upgrades can restart services, so do it at a quiet time and read Supabase's upgrading guide first if you have a paid plan or a large database.

3. If production is down right now, restart once

In the reporter's case in issue #53283, Settings > General > Restart project cleared a multi-day outage immediately. A restart is a short outage of its own, so do it once, then check the error is gone. If it comes back, the upgrade above is the real fix; open a support ticket with the request IDs from your logs if you are already on 14.18 or newer.

4. Add a single retry as a stopgap

// retry a Data API call once when PostgREST reports PGRST303
async function withPgrst303Retry(run) {
  const first = await run()
  if (first.error?.code !== 'PGRST303') return first
  await new Promise((r) => setTimeout(r, 1500))
  return run()
}

const { data, error } = await withPgrst303Retry(() =>
  supabase.from('profiles').select('*').eq('id', user.id).single()
)
// Stopgap only: it hides the intermittent case, not a permanent one.

5. Rule out your own clock if you mint tokens

If your server signs its own JWTs for Supabase (custom auth, a third-party auth provider, or a script), make sure that machine syncs its time (NTP) and do not set iat in the future. Tokens issued by Supabase Auth itself are signed by Supabase, so the user's device clock is not the cause.

How to know it is fixed

After the upgrade, Project Settings > Infrastructure no longer lists a pending upgrade, the curl from step 1 returns 200, and your error tracker shows no new PGRST303 events over the next day of normal traffic, including right after sign-in. Sources: Supabase: PostgREST error PGRST303 "JWT issued at future", PostgREST v14.18 release notes, PostgREST changelog (16.3), supabase/supabase #53283, supabase/supabase #52541, and Supabase: Upgrading. Related: Supabase RLS not working and Invalid API key after the key migration.