I followed the instructions on Google Ads API OAuth setup to create a cloud project and set up an OAuth2 web application for a client ID and secret.
However, when I run GenerateUserCredentials.php via the PHP CLI, it generates a URL. Upon opening the URL in my browser, I encounter the following error:
Error 400: redirect_uri_mismatch
I have tried this process multiple times with different accounts and from a localhost server, but I receive the same error every time.
Could you please advise on how to resolve this issue?
Thank you for your assistance.
![]() |
Google Ads API Team |
Hi,
As per provided information, I understand that you are getting the 'Redirect_URI_Mismatch' error when configuring OAuth setup even after following the given documentation. Please note that we can only assist with technical queries/concerns related to the Google Ads API. If you have any more queries related to the OAuth setup, I would recommend you to reach out to the GCP Product support team for further assistance as they are better equipped to address your concerns. Additionally, I would suggest you refer to Google Cloud Platform help center article for more information.