Skip to content
FunnelGuard

Fix guide by FunnelsGuard

Google or Microsoft SSO button not working: how to fix it

CNV-291High impactPartlyBy FunnelGuardPublished Updated
On this page

What this issue is

SSO (single sign-on) lets people sign up or log in with an existing Google or Microsoft account instead of a new password. It uses OAuth, a standard where your site sends the visitor to Google or Microsoft, they approve, and they come back to your site with a code. The button is broken when any part of that round trip fails: the button does nothing, the provider shows an error page, or the visitor returns to your site but is not logged in.

Why it costs you leads or sales

People who pick SSO are often the ones who want the quickest signup. If that button fails, many will not go back and type a form. They leave, and you never see them because the failure happens on the provider's page or in the browser, not in your form. Work accounts on Microsoft are common in B2B, so a broken Microsoft button can hide your best leads.

Where an SSO signup breaks
  1. Visitor clicks Sign in with GoogleButton is visible and clickable
  2. Redirect to providerError: redirect URI mismatch
  3. Return to your site with codeNever happens
  4. Account createdNo signup
  5. Onboarding and conversion trackingNo event sent

The failure sits in the middle, so every later step is lost.

Signups per 100 visitors who click SSOExample numbers
Signups per 100 visitors who click SSO (example)SSO working: 60 signups; SSO broken: 15 signups023466015SSO workingSSO brokensignups

Example: illustrative numbers only. A working button versus a broken one, assuming some people fall back to the email form.

How to check if your site has it

Reproduce the failure
  1. Open a clean browser

    Use a private window with no extensions and no logged-in Google or Microsoft session. Try desktop and a phone.

  2. Click the button and watch the URL

    If the provider page shows an error, read the code in the page or the address bar (for example error=redirect_uri_mismatch).

  3. Open the browser console and network tab

    Look for blocked scripts, CSP errors, failed requests to accounts.google.com or login.microsoftonline.com, and a blocked popup warning.

  4. Test with different account types

    Try a personal Gmail, a Google Workspace account, a personal Microsoft account and a work Microsoft account. Each can fail for different reasons.

  5. Check your OAuth app in the provider console

    In Google Cloud Console look under APIs and Services, then Credentials and OAuth consent screen. In Microsoft Entra admin center look under App registrations, then Authentication and Certificates and secrets.

Symptoms and likely causes
SymptomLikely cause
Provider error: redirect_uri_mismatch or AADSTS50011Callback URL in the OAuth app differs from the one your site sends (http vs https, www, trailing slash, new domain)
Warning: This app isn't verified, or only test users can log inConsent screen in Testing mode or sensitive scopes not verified
Button does nothingScript blocked or failed, JavaScript error, or a popup blocker
invalid_client or AADSTS7000215Client ID wrong, or client secret expired or copied wrongly
Returns to your site but not logged inCallback code fails: cookies, state mismatch, or email already exists
Works for some users, not work accountsMicrosoft app set to single tenant, or admin consent required

How to fix it

What the visitor sees

The click leads to a provider error instead of your app.

Fix the OAuth setup
  1. Match the redirect URI exactly

    Copy the callback URL your app sends and add it to Authorized redirect URIs (Google) or Redirect URIs (Microsoft). Scheme, host, path and trailing slash must match. Add each domain you use, including staging if needed.

  2. Publish the consent screenGoogle

    In Google Cloud Console, OAuth consent screen, move the app from Testing to In production. If you ask for sensitive scopes, complete verification. Basic sign-in scopes (openid, email, profile) usually need little review.

  3. Set the right account typesMicrosoft

    In Microsoft Entra, App registrations, Authentication, choose Accounts in any organizational directory and personal Microsoft accounts if you want both. Single tenant blocks outside users.

  4. Renew expired secretsMicrosoft

    Microsoft client secrets expire (you choose the period). Create a new secret, paste its Value (not the Secret ID) into your app, then delete the old one. Put the expiry date in your calendar.

  5. Allow the scripts and frames

    If you use a Content Security Policy, allow accounts.google.com, apis.google.com and login.microsoftonline.com in script-src, connect-src and frame-src as your integration needs.

  6. Open the popup from a click

    Browsers block popups not started by a direct user click. Call the sign-in function inside the click handler, or use the redirect flow instead of a popup.

  7. Handle existing emails

    If someone signed up by email before, link the SSO identity to that account instead of failing with a duplicate error.

Where to change it on common platforms
  1. Open the login plugin settings

    In plugins such as Nextend Social Login or Site Kit sign-in add-ons, copy the redirect URI the plugin shows and paste it into your Google or Microsoft app.

  2. Re-enter the Client ID and Secret

    Paste the current values with no spaces. Save, then clear caching so the login page is not served stale.

How to confirm it's fixed

Retest checklist
  • A new personal Google account can sign up and lands in onboarding
  • An existing Google user can log in
  • A personal Microsoft account works
  • A work Microsoft account works (or shows a clear admin consent message)
  • Works in Chrome, Safari and Firefox, and on mobile
  • No errors in the console during the flow
  • Your signup conversion event fires once after SSO signup

How to prevent it happening again

How an expired secret unfolds
  1. Day 0

    Client secret is created with a 6 month expiry (Example)

  2. Month 6

    Secret expires. Nothing changes on the site

  3. Weeks later

    Users report login failures; SSO signups quietly drop

  4. Fix day

    New secret pasted in, SSO works again

Habits that prevent it
  • Calendar reminder 30 days before each client secret expires
  • Keep a list of every domain and callback URL in use, and update the OAuth app when you change domain, add www or move to a new host
  • Keep the consent screen in production and review the contact email
  • Create dedicated test accounts for Google and Microsoft and run the flow after each release
  • Document who owns the OAuth apps so access is not tied to one person who leaves

How FunnelGuard handles this

FunnelGuard does not check SSO buttons yet. It would need dedicated Google and Microsoft test accounts, and this is a possible future check, not a current feature.

What FunnelGuard does run today is your other customer journeys on a schedule, such as lead forms, checkouts and booking or chat buttons. It checks each step and the tracking hits sent to ad and analytics platforms, and re-checks a failure from a second region before sending one alert with a screenshot and a likely cause. If your signup also has an email form path, that path can be watched. The SSO path itself needs a manual check.

To watch SSO in the meantime, test it by hand after each release and on a monthly schedule using your dedicated test accounts, and add your secret expiry dates to a calendar. You can also use an uptime or browser testing tool that you configure with your own test accounts, and track the ratio of SSO clicks to SSO signups in your analytics. A free read-only website audit and a Free plan (1 site, 2 journeys, daily checks, no card) are available at funnelsguard.com.

Questions people ask

Why is my Sign in with Google button not working?

The most common causes are a redirect URI that does not match your OAuth app settings, a consent screen still in Testing mode, a wrong or expired client secret, or a script or popup that is blocked. Click the button in a private window and read the error code in the URL or console to find which one applies.

How do I fix redirect_uri_mismatch in Google login?

Copy the exact callback URL from the error message and add it to Authorized redirect URIs in Google Cloud Console, under APIs and Services, Credentials. It must match scheme, domain, path and trailing slash exactly. Changes can take a few minutes to apply.

What does AADSTS50011 mean on Microsoft sign-in?

It means the reply URL your app sent does not match any redirect URI registered in the Microsoft Entra app registration. Add the exact URL under Authentication, Redirect URIs, and save.

Why does Google SSO only work for some users?

If the consent screen is in Testing mode, only listed test users can sign in. Publish the app to production. For Microsoft, a single tenant app only allows accounts from your own organization.

Why does my social login button do nothing when I click it?

Usually the provider script failed to load, a JavaScript error stopped the click handler, a Content Security Policy blocked the request, or the browser blocked a popup. Check the console and network tab for blocked requests.

Do Microsoft client secrets expire?

Yes. Each secret has an expiry date you choose when you create it. When it passes, sign-in fails with an invalid client error. Create a new secret, update your app with its Value and set a reminder before the next expiry.

Can FunnelGuard monitor my SSO login button?

Not yet. An SSO check is a possible future addition, because it needs Google and Microsoft test accounts. For now test it manually after releases, and use FunnelGuard for your other funnel journeys and tracking.

Does FunnelGuard catch this?

Partly

FunnelGuard checks part of this.

How: login step reports Google / Microsoft blocking an automated sign-in (providerBlock) instead of a timeout; the app's own SSO hosts work with a test account; never worked around.

Stop finding out from your customers

FunnelGuard runs your real forms and checkouts on a schedule, checks the tracking and the leads behind them, and alerts you once, with a screenshot. Try any paid plan free for 3 days.