How can we help?

Table of Contents

MainWP Lighthouse Extension

Install and Set MainWP Lighthouse Extension

  1. Go to your MainWP Dashboard
  2. Go to the MainWP > Extensions page
  3. Click the Install Extensions buttonMainWP Lighthouse Extension 1
  4. Locate the Lighthouse extension and select it
  5. Click the Install button
  6. Once the installation process is complete, click the Activate Extensions buttonMainWP Lighthouse Extension 2
  7. After successful installation, proceed to the extension settings
  8. Insert your Google PageSpeed Insights API key. If you don’t have it, see here how to get it.MainWP Lighthouse Extension 3
  9. Save Settings, and you are ready to audit your sites.

Audit Child Sites

  1. Go to the MainWP > Extensions > Lighthouse > Dashboard page.
  2. Locate the Audit Your Sites buttonMainWP Lighthouse Extension 4
  3. Click it, and wait until the extension completes the process.

Alternatively,  you can use the Bulk Actions menu to audit only certain sites, or if needed ue the Audit Site action from the site Action Menu to audit just one site.

Schedule Automated Audits

  1. Go to the MainWP > Extensions > Lighthouse > Settings page.
  2. Locate the Automatically audit sites option and Enable it.MainWP Lighthouse Extension 5
  3. Locate the Automated audit frequency option and set how often you want to check your sites.MainWP Lighthouse Extension 6
  4. Save Settings.

Get Lighthouse Report for a Site

  1. Go to the Lighthouse extension, Dashboard page
  2. Locate the site you want to check in the list and click use the Lighthouse Report action from the Actions MenuMainWP Lighthouse Extension 7
  3. Once redirected to the report page, you can review all details

Lighthouse Settings

MainWP Lighthouse Extension 8

  • Google PageSpeed Insights API key – In order to run audits, you need to enter your Google PageSpeed API key, if you don’t have it, see here how to get it.
  • Language – Select language for Lighthouse reports.
  • Strategy – Select if you want to get reports for Desktop, Mobile, or Both versions of sites.
  • Notifications threshold – Set the threshold for notifications. If the score goes under the set value, the extension will notify you.
  • Automatically audit sites – If you want the extension to automatically run audits, enable this feature.
  • Automated audit frequency – If automated audits are enabled, here you can set how often you want them to run.
  • Maximum execution time – Change the Max execution time if needed. If the Lighthouse reports are not being completed, increasing this value may help.
  • Maximum script run time – Change the Max script run time if needed. If your scans do not finish completely and changing the Maximum Execution Time does not help, increase this value until you find the maximum allowed runtime.
  • Throttling delay time – Change the Throttling delay time. Increasing this value may slow down Lighthouse reporting, but may help provide more accurate reports on poorly performing web servers.

Audit Sites via WP CLI

Scan one or multiple sites:

wp mainwp-lighthouse audit 125,126

or all

wp mainwp-lighthouse audit --all

Audit Sites via REST API

URI:

/lighthouse/audit

Method:

GET

Required Parameters:

  • site_id – (INT) ID of the child site

Example Request:

https://yourdomain.com/wp-json/mainwp/v1/lighthouse/audit?consumer_key=ck_b587c54fa39976a2ad47b8faf260de84beb70f5d&consumer_secret=cs_75f7a905fa7ae1243570425ede6be026f4731f9c&site_id=129
Still Have a Questions?
Search for additional solutions in the MainWP Community or start your own discussion