Iframe and HTML5 lazy loading, cache preloading and more on WordPress
First impressions matter, and on the web, you make your first impression before anything even loads on your WordPress blog. The time it takes for your homepage or any other WordPress post or page to load determines how long a user stays on your blog, if they even stay at all. Now, with WP Speed of Light Addon's two quickfire updates, you can optimize your blog's loading times and improve SEO further.
The latest update brings two new types of features. First, WP Speed of Light Addon has new features to optimize loading times, notably with the possibility to lazy-load iframes and HTML5 videos. Second, the WordPress plugin now gives you even more flexibility to decide how to cache files, and how to group and minify scripts and stylesheets. Let's dive in!
Iframe and HTML5 video lazy loading on WordPress
If loading times is your priority, then you don't have to look far. In WP Speed of Light's main settings, a new toggleable switch has appeared to boost your WordPress blog's loading times and, with it, your SEO score: Iframe & video lazy loading.
Lazy loading is a speed-up technique that loads multimedia—images and videos, mainly—only when a user scrolls to them. If the user never reaches them, the image or video simply never loads. By loading elements only when and if needed, WP Speed of Light wastes no time and lessens how long your users have to wait before interacting with your blog.
The new feature tackles the worst offenders of all. Iframes, often web-pages or widgets, embed themselves in your WordPress blog—imagine loading several web pages at once. Conversely, HTML5 videos act like regular videos and they too hog loading times.
Luckily, with WP Speed of Light, improving loading times is an exceptionally simple procedure. To enable lazy loading for iframes and HTML5 videos, simply head to the WordPress plugin's settings. Toggle the switch labeled iframe & video lazy loading and harness your improved loading times.
Cache preloading for WordPress posts and pages
The other predominant technique to improve loading times is through caching and preloading. Normally, WordPress generates cache when a user first visits a webpage. With preloading, however, WP Speed of Light generates the cache when you clear it, and thus minimizes the loading times immediately.
Version 3.1 and 3.2 of WP Speed of Light have added support to preload webpages listed in XML sitemaps. Sitemaps guide search engines, like Google, Bing and Yahoo, to find the pages on your website. Normally, then, sitemaps contain links to the most important pages on your blog, or even all of them. In turn, sitemaps represent the ideal tool to preload cache.
To enable cache preloading, head to the advanced tab in WP Speed of Light's settings. Make sure that you have enabled cache preloading and then add links to your sitemaps in the correct field. If you are not sure about the sitemap links, you can use an SEO plugin, such as WP Meta SEO.
From the advanced tab, you can also preload specific pages. Using the Preload the following pages field, you can preload the most visited pages, such as your blog's homepage. Anyone that visits those pages will enjoy rapid loading times, even after you clear your cache.
Caching now also supports clearing the cache for only specific URLs, even if you use a CDN. CDNs serve your WordPress blog's content from servers across the world, delivering webpages from locations situated geographically close to users. With the latest update, you can specify which CDN pages you want to cache.
You can set up your configuration from the CDN integration tab in the plugin's settings. If you have activated your Cloudflare account, scroll down to the section that reads On cache cleanup, also clean. Enable Cloudflare caching and fill in the fields, optionally choosing to purge individual files.
Improving script and stylesheet grouping and minification
As your WordPress website grows and changes, your blog will tend to slow down. Your instinct might tell you to accept the slow-down as inevitable, but speeding up even the most complex of websites does not have to represent an impossible task. Grouping and minification help you control loading times.
Grouping and minification are two optimization tools that often occur together. Most websites use several stylesheets and scripts, each of which entails its own request and therefore adds loading time. Grouping combines all stylesheets into one and all scripts into one, which thus only require one request each. Minification, on the other hand, reduces the size of individual stylesheets or scripts or of groups of stylesheets and scripts, reducing the loading time further.
WP Speed of Light's grouping and minification settings lie in the aptly-named group and minify tab in the settings. Now, in the latest version of the plugin, you can customize how grouping and minification behaves on your blog.
For example, if you are debugging, you might not want to group or minify a certain stylesheet or script, or a certain page. Or you might find that grouping and minification renders your page incorrectly, or that a page cannot work until a stylesheet or script has loaded. From the group and minify tab, you can now both exclude the grouping and minification of inline styles and exclude pages from the optimization.
Optimization is important, but every WordPress blog has different needs. As WP Speed of Light continues to evolve, so does its offering. Versions 3.1 and 3.2 of the addon offer both new features to speed up all blogs—iframe and HTML5 video lazy loading—and new options to tweak how cache preloading, and grouping and minification work.
One of the best features that WP Speed of Light could has is that it is compatible with all the Hostings, for example with Cloudways that is a powerful one :)
If your WordPress blog needs a speed-up, look no further. Learn more about WP Speed of Light here.
When you subscribe to the blog, we will send you an e-mail when there are new updates on the site so you wouldn't miss them.