Problem
You connect a Google account through your own Google app, and the sign-in or a module fails with one of these messages:
Access Not ConfiguredGoogle Drive API has not been used in project 123456789012 before or it is disabled403 accessNotConfigured- In the plugin: The Google Drive API isn't turned on for your project. Turn it on and try again.
Cause
Every Google Cloud project has to turn on the Google Drive API before an app in it can use Google Drive. Google doesn't do this for you, not even for a personal app. The setup in the plugin has a step for it (Turn on the Google Drive API), right after you save the app. When that step was skipped, or done in another project, you get this error.
Solution
- In WordPress, go to Google Drive → Settings and open the setup (Connect your own Google app or Continue setup). In the last step, open Something doesn't work? and click Open the Google Drive API. That button opens the project of your app.
- Check at the top of the Google Cloud page that the right project is selected. Signed in to several Google accounts? Switch to the account that created the app (top right), or use a private window.
- Click Enable. Does Google show Manage instead? Then the API is on already in this project: check that it's the project of your app.
- Wait a minute, then connect the account again (Move or Connect again in the setup).
Without the setup: open Google Drive API in Google Cloud, select the project of your app and click Enable. The number in the error message is the project number; it is also the first part of your Client ID.
The plugin only needs the Google Drive API. You don't need to turn on other APIs or create an API key.