The setup in the plugin shows these steps with buttons that open the right page in Google Cloud, and copy buttons for every value. This article lists the same steps, for when you get stuck or want to read ahead. Start the setup in WordPress: Google Drive → Settings → Connect your own Google app, or on the Dashboard tab: Add a Google app under Your Google apps.
Closed the setup halfway? Open it again. Is your app already saved? Then click Or connect accounts through a Google app you already set up, not Set up a new Google app, which would create a second app. Didn't turn on the Google Drive API yet? See Access Not Configured.
Not sure which type of app to choose? See Which type of app should I choose?
A personal app (4 steps)
Step 1: Create your personal Google app
- Click Open Google Cloud in the setup. It opens the form for a personal app. Sign in with the Google account that you will connect to the plugin.
- App name: copy the name from the setup, or choose your own.
- Application type: Web application. Leave Authorized JavaScript origins empty.
- Under Authorized redirect URIs, click Add URI and paste the address that the setup shows. See Which redirect URI?
- Accept the Google API Services User Data Policy and click Create.
Google shows the Client secret only once. Copy the Client ID and the Client secret, or click Download JSON, before you leave the page.
Step 2: Enter and check the credentials
- Paste the Client ID and the Client secret, or drop the downloaded JSON file on the box.
- Google account that created this app: choose the account. Only that account can connect through a personal app, so the plugin offers the app only for this account.
- Optional: give the app a name, so you can tell your Google apps apart in the plugin.
- Click Check and save. The plugin checks the credentials with Google before it saves them.
Step 3: Turn on the Google Drive API
Click Open the Google Drive API, then Enable. Does Google show Manage instead of Enable? Then the API is on already.
Step 4: Move your accounts
See Move your accounts.
An Internal or External app (6 steps)
Step 1: Create a Google Cloud project
- Sign in with a Google account that belongs to the site owner and will exist for years, not a temporary account or the account of an employee: the app lives in that account.
- Click Open Google Cloud in the setup. Name the project, for example My website – Google Drive, and click Create.
- Select the new project at the top of the page.
Google asks for a credit card or offers a free trial? You don't need either: skip it. "You don't have permission to create a project"? Your Google Workspace administrator doesn't allow this: ask them, or use another Google account.
Step 2: Set up the consent screen
- Click Open Google Auth Platform and then Get started.
- App name: copy the name from the setup. User support email: choose your e-mail address from the list.
- Audience: Internal or External, as you chose in the setup.
- Contact information: your e-mail address. Accept the policy and click Create.
- Skip Data access: you don't need to add anything there.
- Don't upload a logo. A logo means Google has to review your app first.
- Open Branding. Under Authorized domains, click Add domain and add your domain. Use the main domain only, such as
example.comforshop.example.com. Does the setup use the sign-in page of WP Cloud Plugins as redirect URI? Then addwpcloudplugins.comas well. Click Save. If Google asks for an application home page or a privacy policy link, use pages on your own domain.
External apps only: open Audience, click Publish app and then Confirm. If you skip this, the connection stops after 7 days.
Optional: add a second owner. Building the site for someone else, or working in a team? Open IAM, click Grant access, enter the Google account of the second person and choose the role Owner. Then the app doesn't disappear when one person leaves.
Step 3: Create the OAuth client
- Click Create the client in the setup. Keep this Google tab open: Google shows the Client secret only once.
- Application type: Web application. Name: anything you like. Leave Authorized JavaScript origins empty.
- Under Authorized redirect URIs, click Add URI and paste the address that the setup shows (see Which redirect URI?).
- Click Create. Tip: click Download JSON as well. The next step can read that file.
Step 4: Enter and check the credentials
Paste the Client ID and the Client secret, or drop the downloaded JSON file on the box. Optional: give the app a name. Click Check and save.
Do you already have a Google app in the plugin? Then Make this the default app is ticked: new accounts connect through the default app. Untick it if your current app should stay the default. Existing accounts keep their app until you move them.
Step 5: Turn on the Google Drive API
Click Open the Google Drive API, then Enable. Manage instead of Enable means the API is on already.
Step 6: Move your accounts
See Move your accounts.
Which redirect URI?
The setup shows one of two addresses. Copy the one it shows; it must match character for character.
-
Your site's own address, for example
https://example.com/wp-admin/admin-post.php?action=useyourdrive_oauth. After you sign in, Google sends you straight back to your site. -
The sign-in page of WP Cloud Plugins:
https://www.wpcloudplugins.com/use-your-drive/index.php. The setup chooses this address when your site's own address can't be used: when the site doesn't use https, runs on an IP address or a local domain, when WordPress is installed in another folder or on another domain than the site, or when your browser can't reach the address (for example because a security plugin hides wp-admin). With this address, also addwpcloudplugins.comunder Authorized domains.
Is this a staging copy, or can Google not reach your site? Click Use the alternative address instead under the address in the setup. More: Error 400: redirect_uri_mismatch with your own Google app and Your own Google app on a staging, local or http copy of your site.
Good to know about Google apps
Publish an External app, or the connection stops after 7 days. While an External app is in Testing, authorizations expire seven days after consent. Publishing to In production prevents this. Personal and Internal apps don't have this limit. (Google: Manage App Audience)
The Client secret is shown only once. Lost it? Open the client and add a new secret. (Google: Manage OAuth Clients)
Unverified External apps have a limit of 100 accounts. With Entire Drive or Entire Drive (read-only) access, at most 100 different Google accounts can ever connect to an unverified External app. Connecting one or a few accounts is no problem. (Google: Manage App Audience)
Unused clients are deleted. Google deletes OAuth clients with no activity for 6 months. It e-mails you first, and you can restore a deleted client for up to 30 days. (Google: Manage OAuth Clients)