Title: Encaught TypeError \constructor must be an array
Last modified: June 27, 2023

---

# Encaught TypeError \constructor must be an array

 *  Resolved [wpforumskc](https://wordpress.org/support/users/wpforumskc/)
 * (@wpforumskc)
 * [2 years, 11 months ago](https://wordpress.org/support/topic/encaught-typeerror-constructor-must-be-an-array/)
 * Not sure why this started today, but back end of WP site is crashing. Fatal PHP
   errors coming from Site Kit.
 * thrown in /home/xxx/public_html/wp-content/plugins/google-site-kit/third-party/
   google/apiclient/src/Service.php on line 40 [27-Jun-2023 06:17:45 UTC] PHP Fatal
   error: Uncaught TypeError: Google\Site_Kit_Dependencies\constructor must be array
   or instance of Google\Client in /home/xxx/public_html/wp-content/plugins/google-
   site-kit/third-party/google/apiclient/src/Service.php:40
 * Also
 * /home/xxx/public_html/wp-content/plugins/google-site-kit/third-party/google/apiclient-
   services/src/Analytics.php(85): Google\Site_Kit_Dependencies\Google\Service->
   __construct(Object(Google\Site_Kit\Core\Authentication\Clients\Google_Site_Kit_Proxy_Client))

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

 *  Plugin Support [James Osborne](https://wordpress.org/support/users/jamesosborne/)
 * (@jamesosborne)
 * [2 years, 11 months ago](https://wordpress.org/support/topic/encaught-typeerror-constructor-must-be-an-array/#post-16850986)
 * Thanks for getting in touch [@wpforumskc](https://wordpress.org/support/users/wpforumskc/).
   So we can determine more on this and ensure Site Kit works as expected, please
   share the following:
    1. Your[ Site Health information](https://i.imgur.com/Rtkmsba.png). You can[ use this form](https://docs.google.com/forms/d/1lhjns2K7c0Ny7ME4gxTcsnYtNUtcMr8BvFpPQi23Y1E/)
       to share privately if preferred.  
    2. Can you try to deactivate and uninstall Site Kit before installing once more
       and checking does this error appear? If you remain without have access to your
       wp-admin panel you can manually deactivate Site kit via removing the plugin 
       directory using FTP or your web hosting file manager (`wp-content/plugins/google-
       site-kit`).
 * Once we have the above we can investigate this further. Some troubleshooting 
   steps we may suggest is switching PHP version temporarily, or checking for third
   party plugin conflicts.
 * Let me know if you have any questions with the above.
 *  Thread Starter [wpforumskc](https://wordpress.org/support/users/wpforumskc/)
 * (@wpforumskc)
 * [2 years, 11 months ago](https://wordpress.org/support/topic/encaught-typeerror-constructor-must-be-an-array/#post-16851074)
 * Reinstall worked. thanks.
 *  Plugin Support [James Osborne](https://wordpress.org/support/users/jamesosborne/)
 * (@jamesosborne)
 * [2 years, 11 months ago](https://wordpress.org/support/topic/encaught-typeerror-constructor-must-be-an-array/#post-16851140)
 * Glad to hear it [@wpforumskc](https://wordpress.org/support/users/wpforumskc/).
   If you run into any further errors or if you have any Site Kit related queries
   be sure to get in touch.

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

The topic ‘Encaught TypeError \constructor must be an array’ is closed to new replies.

 * ![](https://ps.w.org/google-site-kit/assets/icon-256x256.png?rev=3141863)
 * [Site Kit by Google - Analytics, Search Console, AdSense, Speed](https://wordpress.org/plugins/google-site-kit/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/google-site-kit/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/google-site-kit/)
 * [Active Topics](https://wordpress.org/support/plugin/google-site-kit/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/google-site-kit/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/google-site-kit/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [James Osborne](https://wordpress.org/support/users/jamesosborne/)
 * Last activity: [2 years, 11 months ago](https://wordpress.org/support/topic/encaught-typeerror-constructor-must-be-an-array/#post-16851140)
 * Status: resolved