惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

阮一峰的网络日志
阮一峰的网络日志
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
Blog — PlanetScale
Blog — PlanetScale
Jina AI
Jina AI
MyScale Blog
MyScale Blog
N
Netflix TechBlog - Medium
月光博客
月光博客
云风的 BLOG
云风的 BLOG
T
The Blog of Author Tim Ferriss
博客园_首页
GbyAI
GbyAI
The Cloudflare Blog
博客园 - 叶小钗
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
MongoDB | Blog
MongoDB | Blog
Y
Y Combinator Blog
博客园 - 三生石上(FineUI控件)
量子位
博客园 - Franky
WordPress大学
WordPress大学
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
人人都是产品经理
人人都是产品经理
F
Fortinet All Blogs
Martin Fowler
Martin Fowler
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
M
MIT News - Artificial intelligence
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
I
InfoQ
Google DeepMind News
Google DeepMind News
S
SegmentFault 最新的问题
大猫的无限游戏
大猫的无限游戏
Apple Machine Learning Research
Apple Machine Learning Research
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
Stack Overflow Blog
Stack Overflow Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
Last Week in AI
Last Week in AI
J
Java Code Geeks
腾讯CDC
aimingoo的专栏
aimingoo的专栏
C
Check Point Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
V
Vulnerabilities – Threatpost
S
Schneier on Security
D
Darknet – Hacking Tools, Hacker News & Cyber Security
L
Lohrmann on Cybersecurity
S
Securelist
F
Full Disclosure
Cisco Talos Blog
Cisco Talos Blog
小众软件
小众软件
The GitHub Blog
The GitHub Blog

Pressable

Pressable Achieves Secure Hosting Alliance Certification | Pressable How Pressable MCP Is Changing The Game For WordPress Agencies: A Live Breakdown With Matt Medeiros And Phill Clapham | Pressable April Product Update: Navigation, Organization, And Efficiency | Pressable White-Label WordPress Hosting For Profitable Agencies | Pressable A Guide To Client Onboarding For WordPress Agencies| Pressable WordPress Plugin Management for Agencies WordPress Maintenance Contracts For Agencies: A Complete Guide | Pressable 6 Essential SOPs For WordPress Agencies | Pressable Pressable MCP: Control Your WordPress Hosting With AI. | Pressable How Much Does WordPress Hosting Cost? WordPress Performance Budgets: Setting And Monitoring Goals | Pressable WordPress Automation With No Code Automation Tools | Pressable Implement Single Sign-On (SSO) In WordPress | Pressable How To Build A Real Estate Site On WordPress | Pressable Headless WordPress Showdown: Next.js Vs Gatsby | Pressable How To Automate White-Label WordPress Hosting With WHMCS | Pressable Developer Toolkit Update: Automation & UI Enhancements | Pressable How To Build A DXP Platform With WordPress How To Boost WordPress Agency Client Retention: 4 Strategies White Label WordPress Admin For Agency Clients Performance Testing For WordPress Agency Client Sites Performance Testing For WordPress: A Framework For Agency Client Sites How To Upload A Video To WordPress | Pressable How To Mitigate The Impact Of AI Scraper Bots On WordPress Sites WooCommerce ERP Integration: Automate Your Back Office WordPress Personalization: How To Display Tailored Content To Visitors | Pressable WooCommerce Conversion Rate Optimization: A Data-Driven Approach How To Price Your Online Course: WordPress Monetization Guide 7 Ecommerce KPIs You Should Be Measuring (and How to Optimize Them) WooCommerce Vs. BigCommerce: Which Is Best For Your Business Needs? | Pressable WooCommerce Performance Troubleshooting: Diagnosing Speed Issues Step-by-Step | Pressable AI Content Moderation Tools for WordPress: Fighting Back Against AI Spam WordPress Vs. Craft CMS: Which Is Right For Your Business Site? | Pressable Questions To Ask Before Migrating From Shopify To WooCommerce Outgrowing Squarespace? WooCommerce Can Help WordPress Automation: Google Docs To WordPress Workflow WooCommerce Subscription Strategies: How to Build Recurring Revenue for Your Store Is WordPress Easy To Learn? A Beginner’s Guide WooCommerce Database Optimization With Query Monitor | Pressable WPForms Vs Gravity Forms: Which WordPress Plugin Works Best For Growing Businesses? WooCommerce Vs. Shopify: Choosing The Right Platform The Best AI Chatbots for WordPress Rank Math Vs Yoast: Best WordPress SEO Plugin? 5 Ways AI For Ecommerce Boosts WooCommerce Sales | Pressable WordPress Cookie Consent: What Site Owners Need To Know | Pressable How To Optimize Your WooCommerce Store For AI Search | Pressable WordPress Local SEO: A Guide To Local Search For SMBs | Pressable How to Improve Your WordPress Site’s Search Experience WordPress vs. Substack: Find the Best Platform for Your Newsletter WordPress vs. Ghost: Comparing Open-Source Blog and Newsletter Solutions A Comprehensive Migration SEO Checklist For WordPress Drupal vs. WordPress: Comparing Open Source Content Management Systems How To Add Enterprise-Level Search Capabilities To WordPress Sites What Are WordPress Nonces And How To Use Them | Pressable How To Customize WordPress Without Breaking Your Theme | Pressable WooCommerce vs. Magento (Adobe Commerce): Which is Better for Your Online Store? Prepare Your WooCommerce Store For A High-Traffic Product Drop Tips On Building A Successful WordPress Sales Funnel | Pressable Best WordPress Integrations For Workflow Automation | Pressable WooCommerce Vs. Wix: WooCommerce Explained For Wix Users | Pressable How To Choose WordPress Lead Generation Plugins | Pressable GA4 For WordPress: Understanding Your Data | Pressable WordPress Accessibility for Visually Impaired Users WordPress Information Architecture For Businesses | Pressable How To Use WordPress As A Headless CMS | Pressable How To Use Composer For Modern WordPress Development | Pressable WordPress GitHub Workflows: Version Control Best Practices How To Evaluate A WordPress Plugin Before Installing It | Pressable Billing Clients For WordPress Hosting | Pressable Advanced WooCommerce Cart Abandonment Strategies | Pressable How To Perform A WordPress Security Audit | Pressable How Managed WordPress Hosting Reduces Ops Workload | Pressable The Ultimate Ecommerce CRO Guide | Pressable How to Set Up a Business Continuity Plan for Your WordPress Website How to Hire the Best WordPress Developer for Your Site Common Mistakes When Choosing A WordPress Host | Pressable Beaver Builder Vs. Elementor: Which Page Builder Is Better Streamlining Website Handoff With Managed WordPress Hosting How WordPress Agencies Build Recurring Revenue | Pressable How To Customize WooCommerce Product Pages | Pressable SEO Tip For Migrating Your WordPress Domain | Pressable When To Switch To Enterprise WordPress Hosting | Pressable WooCommerce PIM Tools For Growing Ecommerce Stores | Pressable Automating WordPress Security: Tips To Prevent Cyberattacks Integrating POS With WooCommerce | Pressable Scale Your WordPress: Automation Tips For Growth, Efficiency, And Reliability | Pressable How To Edit Your WordPress Database Safely | Pressable Boosting Conversions, Not Load Times: Performance-Focused A/B Testing of Landing Pages in WordPress WooCommerce Migration: Avoid Downtime and Data Loss With These Essential Tips How To Improve Core Web Vitals on Your WordPress Site How To Run Successful SEO Experiments On WordPress | Pressable Automated WordPress Website Backups | Pressable Grow Ecommerce Sales With WooCommerce Dynamic Pricing LearnDash vs LifterLMS: Which WordPress LMS is Right for You? What Is High Availability Hosting For WordPress? | Pressable Tips On Managing WooCommerce Traffic Spikes | Pressable What To Do When A WordPress Plugin Breaks Your Site Automating Agency Workflows With WordPress Webhooks How To Automate Tasks In WooCommerce With Action Scheduler Why WordPress Downtime Costs And Uptime Guarantees Matters WordPress Cleanup: How to Uninstall WordPress Plugins Without Breaking Your Site
Boost Your Google PageSpeed Insights Score | Pressable
Zach Wiesman · 2022-04-07 · via Pressable

Tips to Improve Google PageSpeed Insights Score

Ask Your Favorite AI

Copy the link to a markdown format of this article for ChatGPT, Claude, Gemini, or your favorite AI.

Google has gradually been increasing the importance of site speed as a ranking signal since mobile-first indexing was introduced in 2016. In their own words, “Speed equals revenue.”

When a page takes too long to load, visitors move on to another page to find answers quicker. Slow speed discourages visitors from staying on your site, irrespective of how they’ve found you (organic search, referral link, paid ads).

In addition to improving the user experience (UX) of your site, a fast site also improves overall SEO.

If your website is fast, you have a greater chance of ranking higher than slower sites with high bounce rates.

  • Visitors are 106% more likely to bounce as page load time goes from one second to six seconds.
  • A one-second delay in the loading speed of mobile sites can impact conversion rates by up to 20%.
Source: Think With Google

A Backlinko study that analyzed 11.8 million Google search results found, quite surprisingly, that there was “no correlation between page loading speed and first page Google rankings.” It did explain that Google’s Speed Update affects only extremely slow pages and downranks them instead of benefiting fast pages.

However, the study found that the average page loading speed for results on the first page is 1.65 seconds.

Source: Backlinko

Furthermore, a 2019 study by Portent found that sites should aim for a 0-2 seconds load time to improve transaction conversions.

Source: Portent

Above all, Google has confirmed that page speed is a ranking factor for both mobile and desktop searches and recommends the use of PageSpeed Insights and Lighthouse to evaluate site performance.

So, improving your page speed should be a priority to enhance the user experience and boost search engine rankings.

How does PageSpeed Insights work?

PageSpeed Insights is a free performance evaluation tool that analyzes any URL and provides a score out of 100 for both its mobile and desktop versions. It also offers several recommendations for improvement and identifies opportunities for optimization.

Source: Search Engine Land

The tool is powered by Lighthouse that provides lab data and field data.

  • Field data is gathered from real-world performance data contained in the Chrome User Experience Report (CrUX) when visitors load your page. It identifies bottlenecks that prevent real visitors from converting on your page. It includes:
  • First Contentful Paint (FCP) – time taken for the first text or image asset to load
  • Largest Contentful Paint (LCP) – time taken for the largest text or image asset to load
  • First Input Delay (FID) – time taken by the browser to respond to the visitor’s first interaction
  • Cumulative Layout Shift (CLS) – measures any movement of the page in the viewport
  • Lab data measures the speed of the webpage in a simulated, controlled environment like mobile networks and a mid-tier device. It’s a good way to detect performance issues and find solutions to fix them. It calculates FCP, LCP, CLS, and three more metrics:
  • Speed Index (SI) – time taken for the content to visually appear during page loading
  • Time to Interactive (TTI) – time taken for the page to become completely interactive
  • Total Blocking Time (TBT) – total time of FCP and complete interactivity

Getting a 100/100 score isn’t a direct indicator of page speed. You can have a fast-loading website without achieving a perfect score.

Neither do visitors care about a perfect score. All they want is to view your content quickly. So it’s more important to focus on implementing the recommendations given by the tool.

The performance metric results used to calculate your score have different weightages.

This table gives the weights for lab data in Lighthouse 8:

Performance metric Weightage
FCP 10%
SI 10%
LCP 25%
TTI 10%
TBT 30%
CLS 15%

Instead of these weightages, what you’re shown is an aggregate performance score and a color that denotes your score bucket:

  • Red (poor): 0 – 49
  • Orange (average): 50 – 89
  • Green (good): 90 – 100

The tool provides detailed action items in the Opportunities section to help you improve your score.

How to improve your PageSpeed Insights score

Based on the recommendations offered by the PSI tool, here are 12 ways in which you can improve your performance score:

Avoid Post-Click Landing Page Redirects

Redirects are commonly used when you delete or move a page on your website.

They increase time-to-first-byte (TTFB), which is the amount of time taken between a request to the server and when the first byte of data is sent back to the requester. While there’s nothing inherently wrong with using redirects, excessive use causes delays in page loading.

Ensure you use redirects only when necessary to improve page loading speeds and improve overall SEO.

Minify CSS, HTML, and JavaScript

Minification refers to the process of eliminating or fixing unnecessary or duplicated data without affecting how a browser processes HTML. It involves removing unnecessary spaces, characters, and duplications.

Minifying CSS, HTML, and JavaScript reduces the size of these files and improves page loading speed.

Source: WP Buffs

Use plugins like WP Rocket, HTML Minify, or Autoptimize to automatically minify your code in WordPress.

Prioritize Above-the-Fold Content

Lazy loading involves prioritizing the loading of images that are immediately visible instead of making the browser load all the images on the page before displaying above-the-fold content. It reduces the amount of time taken to reach FCP and FMP.

By prioritizing above-the-fold content and deferring offscreen images, you can improve site performance. If you have implemented “infinite scrolling” as most content-heavy sites do, you must use lazy loading.

Source: WordStream

Use WordPress plugins like Lazy Load by WP Rocket and a3 Lazy Load. Autoptimize also has lazy loading features.

Speed Up Server Response Time

Server response time or TTFB is a measure of how long the browser is required to wait before it gets its first byte of data from the server. The longer this period is, the longer it takes for the page to load.

A low TTFB is not the same as a fast overall site speed, but a fast server response time improves site performance.

Source: WordStream

Methods to speed up server response times:

  1. Use a fast WordPress host –  A quality WordPress-focused hosting provider has a carefully thought-out architecture and prioritizes speed.
  2. Implement a Content Delivery Network (CDN) – If you have a website that serves visitors around the world, using a CDN will significantly lower your TTFB.
  3. Use WordPress caching – Caching can decrease page load times as well as TTFB because it reduces server processing time. We recommend Pressable’s built in caching options.
  4. Select a premium Domain Name System (DNS) provider – Typically, with premium DNS providers, DNS lookup times are faster. However, Cloudflare is a free DNS provider that offers excellent performance.

Eliminate Render-Blocking Resources

Render-blocking resources are static files like JavaScript, CSS, HTML, and fonts that are crucial for the rendering of a webpage. The visitor’s browser is required to download and process these files before the rest of the page can be displayed.

Thus, having a lot of these files “above the fold” creates a bottleneck and slows down site speed.

Source: Online Media Masters

There are two methods to remove render-blocking resources:

  1. Inlining – If your webpage does not have a lot of JavaScript or CSS, consider inlining them i.e. incorporating the JavaScript and/or CSS code into the HTML file. You can use a plugin like Autoptimize to inline your code if you use WordPress. Note that this method works only for very small sites. Most WordPress sites have enough JavaScript that this technique could be counterproductive.
  2. Async and Defer – For large websites, use the async and defer attributes to eliminate render-blocking. The defer attribute downloads the scripts during HTML parsing but executes it only after completion of parsing. It also executes them in order of appearance on the page. Scripts with the async attribute execute as soon as downloading is complete.

Minimize Main-Thread Work

The “main thread” is the chief element of a user’s browser that is tasked with changing code into a webpage that visitors can work with. It has two functions: it parses and executes JavaScript, HTML, and CSS and handles user interactions.

When the main thread is working on the site’s code, it cannot simultaneously handle user requests. Thus, if the main-thread work takes too long (>4 seconds), it leads to slow page loading speed and poor UX.

Source: Marfeel

Methods to minimize main-thread work:

  1. Minify CSS, HTML, JavaScript – Use inlining or deferring to reduce file sizes.
  2. Remove unused code – Just like you minify code, consider inlining or deferring styles in whatever manner works for your webpage. Use tools like ChromeDevTools to find unused JavaScript and CSS code.
  3. Implement browser caching – It involves saving copies of previously-loaded resources so the browser does not have to reload them on every visit. Use tools like W3 Total Cache for WordPress websites.
  4. Implement code-splitting – It is an advanced technique that involves splitting JavaScript into bundles to execute when required instead of having browsers load all the code before the webpage becomes interactive. Use webpack to implement code splitting.

Serve Images in Next-Gen Formats

Images in next-gen formats like JPEG 2000, JPEG XR, and WebP load faster than commonly-used file formats like JPEG and PNG.

  • WebP offers 25% to 35% smaller file sizes than JPEG with the same quality.
  • WebP images result in a 42.8 percent decrease against PNG images.

WebP images are increasingly becoming the standard format for images and plugins like Smush and Imagify offer a WebP conversion feature.

Leverage Browser Caching

Browser caching is a basic optimization that enables your webpages to load faster for repeat visitors. When the visitor moves to a new page on your site, caching ensures that all your data (like logos and fonts) does not have to be reloaded.

This results in a vast improvement in site speed.

Source: KeyCDN

Pressable customers can take advantage of our premium edge caching that’s included with all of our plans. Websites on other hosts can rely on plugins like W3 Total Cache, WP Super Cache, and WP Rocket for WordPress websites to implement browser caching.

Google PageSpeed Insights requires you to have an “efficient” cache policy. This means that you need to optimize the frequency at which your browser clears its cache. But you don’t want it to be too often because it defeats the purpose of having browser caching.

You can optimize your cache expiration period by adding Cache-Control and Expires headers to an Nginx server. If you have Apache servers, you can edit or create a .htaccess file (with the help of a web developer).

You can also consider hosting Google Analytics locally with plugins like Perfmatters and Complete Analytics Optimization Suite (CAOS).

Avoid Large Layout Shifts

Large layout shifts lead to a frustrating user experience because page elements appear suddenly, shift around, and interfere with how visitors interact with the webpage. When layout shifts happen, just as a visitor is about to click or tap on an element (buttons, images, contact forms), the screen moves down and they’ve clicked on something else.

Avoiding large layout shifts is particularly important for mobile devices. A poor CLS score indicates that your webpage is “janky,” or visually unstable.

Source: Generate Press

Ways to prevent large layout shifts:

  • Specify image dimensions – Set the width and height for images and video elements so that correct spacing is used for images and videos. You can also do this using CSS aspect ratio boxes.
  • Reduce layout shifts caused by embeds, ads, and iFrames – You can take several actions to minimize layout shits due to iFrames, ads, and embeds:
    • Use placeholders when no ads are available for display
    • Shift ads to the bottom or outside the viewport
    • Reserve the largest ad slot before loading the ad library
  • Avoid inserting dynamic content above existing content – You can avoid large layout shifts by not inserting new content like banners and forms above existing content unless it is in response to visitor interaction.
  • Prevent the Flash of Invisible Text (FOIT) – Your CLS score can be affected by FOIT issues. You can preload fonts and/or use the font-display attribute to ensure that your text should remain visible during font loading.
  • Avoid non-composited animations – With the help of a web developer, perform only composited animations wherever possible to minimize main-thread work and avoid repainting of pixels during page loading.

Optimize Images

Slow pages and low PageSpeed Insights scores are mainly caused by large images. Optimizing images helps lower FCP and LCP times and prevents CLS issues.

Source: Tech Learn

Here are a few ways in which you can optimize images:

  1. Resize and compress images: Use plugins like WP Smush Image or Crush.pics to save, on average, 50 percent or more on image size. You can also use online tools like Optimizilla and Compress JPEG.
  2. Set standards: Define standards for format and the maximum resolution of images for the site
  3. Use a CDN to deliver your images: Use a content delivery network so images are delivered faster.
  4. Use responsive images – It involves creating images of different sizes for different devices by using the srcset attribute, which gets added to <img> tags to specify alternate image files in varied sizes. Browsers read this list, decide which image size is suitable for the current device, and display that version of the image.

Reduce the Impact of Third-Party Code

Third-party scripts can lower the performance of your site by prolonging main-thread work. Examples of third-party scripts are:

  • Google Analytics
  • Libraries for JavaScript and fonts
  • iFrames for ads and other content
  • YouTube video embeds
  • Social media sharing buttons and feeds

While some of these may be necessary for your website, there are ways to minimize their impact:

  1. Defer the loading of JavaScript
  2. Locally host third-party scripts like Google Analytics
  3. Use link tags with preconnect attributes

Avoid an Excessive DOM Size

The Document Objective Model (DOM) is how browsers transform HTML into objects. It uses a tree structure with several individual nodes that represent each object. The larger the DOM size, the longer it will take your webpage to load.

Google PageSpeed Insights will recommend that you reduce the number of nodes and the complexity of your CSS styling.

You should also use a lightweight website theme that uses GZIP compression or has a more responsive design. Heavy themes add more volumes of elements to the DOM and may have convoluted styling that slows page loading speeds.

Over to you

Google PageSpeed Insights is an invaluable tool for site owners and marketers, even those with less technical knowledge. By following the recommendations in the PSI report (but not obsessing over getting a perfect score), you’re sure to boost your website’s rankings in SERPs.

Zach Wiesman

Zach brings a wealth of knowledge to Pressable with more than 15 years of experience in the WordPress world. His journey in WordPress began with creating and maintaining client websites, fostering a deep understanding of the intricacies and challenges of WordPress. Later, his knack for problem-solving and commitment to service led him to pursue a role at Automattic, where he excelled in providing customer support for WooCommerce. His expertise extends beyond technical proficiency to encompass a deep understanding of the WordPress community and its needs. Outside of work, Zach enjoys spending time with his family, playing and watching sports, and working on projects around the house.