
My company utilizes both Google Workspace and WordPress, so I wanted to make it easy for the team to log into the website using Google OAuth. A couple of caveats to this before I get started:
- Internal Use: I only want users within our domain to access our site, not external users. That simplifies this because my project won’t need to be approved by Google Cloud.
- Users: My users were already set up in WordPress, where the user’s email address matches the Google Workspace user’s email address. There is an option to allow registrations to create new users, but I didn’t want to do that (for now).
There are many paid integration solutions for single sign-on (SSO) and/or OAuth, but I don’t think it’s necessary to pay in this case. I found a great plugin called Log in with Google that appears to be supported well, and it worked perfectly for my scenario.
Add a Project in Google Cloud for Your OAuth
The difficult part isn’t setting up the plugin; it’s logging into Google Cloud’s console and creating your project. Google Cloud has so many features and settings that it’s easy to get lost in there. The documentation on the plugin and on Google Cloud isn’t so great, so I thought I’d walk you through it here.
- Register and Login to Google Cloud – If you’ve never done that before, you’ll need to accept the terms to get started and create an organization to work under. Navigate to the API console.
- Add a New Project

- OAuth Consent Screen (App information) – Ensure you’re working within your project by selecting it from the top of the page (not sure why Google wouldn’t take you directly there!) and then fill out all of the necessary information.

- OAuth Consent Screen (Update selected scopes) – Add the Scope permissions you’ll need for OAuth to work. These are
...auth/userinfo.email
and...auth/userinfo.profile
. Click Update.
- OAuth Consent Screen (Confirm) – Confirm your settings.

- Credentials – On the left menu, select Credentials. From the top menu, select Create Credentials and select OAuth client ID.

- Create OAuth client ID for the application type Web application.

- Create OAuth client ID – Name your web application and then enter the redirect, which should be your URl followed by
/wp-login.php
.

- Create your credentials – and you’ll get a popup with your Client ID and Client Secret. Keep those handy; they’ll need to be entered in the plugin settings.
Activate the Log in with Google WordPress Plugin
The plugin is no frills and is straightforward. There’s not a lot of documentation around it, though, so I wanted to provide the visual steps above.
- Enter your Client ID from Google Cloud.
- Enter your Client Secret from Google Cloud.
- Select whether or not you’d like to create new user if that email address isn’t registered.
- Enable One Tap Login to directly login to WordPress Admin.
- Enable whether you’d like this to work only on the Login Screen or throughout the site wherever someone is logging in.
- Add your domain.

- Save Changes and you’re good to go!
- Log out of WordPress, use the Google Login, and you’ll be able to authenticate for your WordPress site:
