How to Enable the Google PageSpeed Insights Widget in W3 Total Cache
You can use W3 Total Cache to connect to the Google PageSpeed Insights API so that you can see your website’s speed and get suggestions to optimize your WordPress website even further using those scores directly from the Performance Dashboard. Not only will you get an overview of your website performance directly on your dashboard, but you can get a PageSpeed score for every page on your WordPress website from the Admin Toolbar at the top. Cool, right? Use the following instructions to create a Google PageSpeed Insights API Key and connect them to your W3 Total Cache WordPress performance plugin to get insight into your next steps for making your website pages load faster than ever before.
Create your Google Cloud Project
- Log into your Google Account and navigate to the Google Cloud Console located at https://console.cloud.google.com
- If this is your first Google Cloud project for your website, click on Select a Project.
- If you already have a project set up for your website, choose that project. If you have another project set up for other reasons, it’s best practice to create a new project dedicated to this website. You will thank us for this advice later.
- Name your project with a name unique to this website so it is easy to understand later, and click Create.
Enable the PageSpeed Insights API
- Click on APIs and Services from the menu.
- Click Enable APIs and Services at the top of the screen.
- Start typing Pagespeed into the search bar, and when it appears from the list of APIs, click PageSpeed Insights API.
- Click on Enable on the next screen.
Create Your PageSpeed Insights API Key
- After enabling the API, you’ll be brought to the PageSpeed Insights Overview screen. Click on Create Credentials near the top.
- Look for the option to skip this stem and create an API key.
- Optionally create a name for your API Key, and under Application Restrictions choose HTTP referrers.
- Enter your domain into the field, using wildcards and the appropriate http/https protocol, e.g. https://*.example.com/*
- Click Create and copy your new key to your clipboard.
Enter your API Key into W3 Total Cache
- Navigate back to your WordPress Dashboard’s Performance -> General Settings -> Miscellaneous section.
- Click Enable Google Page Speed dashboard widget and paste your API key and HTTP Referrer into the fields.
- The PageSpeed Insights widget will now be visible on your Performance -> Dashboard screen.
Congratulations! Now you know how to connect your W3 Total Cache Dashboard Widget to Google PageSpeed Insights so that you can optimize WordPress for speed even more effectively. Next, you may want to learn how to set up W3 Total Cache debugging to troubleshoot your caching configuration or learn how to set up Caching Statistics for detailed insight if you are a W3 Total Cache Pro User.
W3 Total Cache
You haven't seen fast until you've tried PRO
Full Site CDN + Additional Caching Options
Advanced Caching Statistics, Purge Logs and More
Everything you need to scale your WordPress Website and improve your PageSpeed.