Title: Error translating from Google API
Last modified: June 21, 2020

---

# Error translating from Google API

 *  Resolved [Guilherme Frisoni](https://wordpress.org/support/users/frisoni/)
 * (@frisoni)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/error-translating-from-google-api/)
 * When I try to translate a string I got a FAILED message.
    Checking Network Inspector,
   google sent a 403 error. I could see a OPTIONS method ena API key is sent in 
   Form data.
 * When I try to send API_KEY in get parameters i get response.
    Example: [https://translation.googleapis.com/language/translate/v2?source=en&target=pt&format=text&key=AIzaSyASvBZRa02Z1WaUAsipoVTmyaB1qkFktYc&q=hello](https://translation.googleapis.com/language/translate/v2?source=en&target=pt&format=text&key=AIzaSyASvBZRa02Z1WaUAsipoVTmyaB1qkFktYc&q=hello)
 * What I’m missing?

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [Tim W](https://wordpress.org/support/users/timwhitlock/)
 * (@timwhitlock)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/error-translating-from-google-api/#post-13018224)
 * Possibly your API key is restricted. Did you see all the [instructions here](https://localise.biz/wordpress/plugin/manual/providers#google)?
 *  Thread Starter [Guilherme Frisoni](https://wordpress.org/support/users/frisoni/)
 * (@frisoni)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/error-translating-from-google-api/#post-13018804)
 * Found it.
 * Yes, I created an API key without any restriction.
    I found another erros in 
   console log when trying to connect API:
 * Access to XMLHttpRequest at ‘[https://translation.googleapis.com/language/translate/v2?source=en&target=pt&format=text&#8217](https://translation.googleapis.com/language/translate/v2?source=en&target=pt&format=text&#8217);
   from origin ‘[https://www.cuscoloko.com.br&#8217](https://www.cuscoloko.com.br&#8217);
   has been blocked by CORS policy: Response to preflight request doesn’t pass access
   control check: No ‘Access-Control-Allow-Origin’ header is present on the requested
   resource.
 * In that call a notice this header: X-CSRF-UAP-ADMIN-TOKEN: c7af1c8a61
 * It is inserted by this plugin: Indeed Ultimate Affiliate Pro
    Just deactivated
   this plugin and it works fine.
 * Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Error translating from Google API’ is closed to new replies.

 * ![](https://ps.w.org/loco-translate/assets/icon-256x256.png?rev=1000676)
 * [Loco Translate](https://wordpress.org/plugins/loco-translate/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/loco-translate/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/loco-translate/)
 * [Active Topics](https://wordpress.org/support/plugin/loco-translate/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/loco-translate/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/loco-translate/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [Guilherme Frisoni](https://wordpress.org/support/users/frisoni/)
 * Last activity: [5 years, 11 months ago](https://wordpress.org/support/topic/error-translating-from-google-api/#post-13018804)
 * Status: resolved