1-) Go to the Google API Console website: https://console.developers.google.com/
2-) Select or create a new project. Then go to the OAuth consent screen. Select the option External for User Type. Then click the Create button.
3-) Fill in all the required information about your website (Application Name, Authorize Domains, links to the Home Page, Privacy Policy and Terms of Use)
4-) Go to Credentials. Click the +Create Credentials button. Then select the OAuth client ID option.
5-) For Application Type choose the Web Application option. Give it a Name. For Authorized Javascript Origins, enter the home page link of your website. For Authorized Redirect URLs, you need to enter the home page link with the following extension:
sponsors/googleauth.php.
For example https://test.com/sponsors/googleauth.php
If you don't enter this information exactly as it is described, the integration won't work.
When you are done, click the Create button.
6-) Copy your Client ID and Client Secret.
7-) Go back to your site manager. Go to Configuration -> Social Media Configuration. Select the Allow checkbox. Paste your Client ID and Client Secret. Then click the Save Changes button.