Loading documents preview...
WordPress Speed Optimization Jakarta WordPress Meetup #14
Ivan Kristianto @ivankristianto
Who Am I? •
My name is Ivan Kristianto
•
Senior Web Engineer at 10up
•
WordPress core contributor
•
ElasticPress team member
•
Jakarta WordPress Meetup Organizer
Who Love Fast Websites? Why?
How Fast is Fast Enough? •
If your site loads in 5 seconds, it is faster than approximately 25% of the web
•
If your site loads in 2.9 seconds, it is faster than approximately 50% of the web
•
If your site loads in 1.7 seconds, it is faster than approximately 75% of the web
•
If your site loads in 0.8 seconds, it is faster than approximately 94% of the web
SOURCE: HTTPS://WWW.SEMRUSH.COM/BLOG/HOW-FAST-IS-FAST-ENOUGH-PAGE-LOAD-TIME-AND-YOUR-BOTTOM-LINE/
How to have site load < 3s?
Server Side 1. Server Specification ( CPU, RAM, Network Speed, SSD , Location ) 2. Server Services & Settings: i. Web Server: Apache, Nginx, Litespeed, etc. ii. Database Server: MySQL, MariaDB iii. Cache ( Redis, Memcache, Varnish, Litespeed Cache, etc.. ) iv. PHP Version and Modules
WordPress side 1. Object Caching ( https://codex.wordpress.org/Class_Reference/WP_Object_Cache ) 2. DB Query Cache 3. Page Cache 4. Minification: JS, CSS and HTML
The Challenge
Shared Hosting
Server Specification •
Location: Singapore
•
CPU Core: 20. Avg Load: 2.89
•
Memory Average load: 21%
•
Swap Used: 38%
•
Disk Usage: 29%
•
Web Server: Litespeed
•
Database: MariaDB 10.2.14
•
PHP Version: 7.1
•
Memcache
WordPress Plugins •
LiteSpeed Cache*
•
Query Monitor
•
WooCommerce
•
Gutenberg
•
EWWW Image Optimizer
LiteSpeed Cache Plugin
Object Cache: Memcache LiteSpeed Cache Advance Settings
•
CSS Minify, Inline CSS Minify, CSS Combine, CSS HTTP/2 Push: On
•
JS Minify, Inline JS Minify, JS Combine, JS HTTP/2 Push: On
•
HTML Minify: On
•
Load CSS Asynchronously: Off
•
Load JS Deferred: On
Optimize Settings LiteSpeed Cache [5] Optimize
•
Combined CSS Priority: On
•
Combined JS Priority: On
•
Remove Query Strings: On
•
Load Google Fonts Asynchronously: On
•
Remove WordPress Emoji: On
Tuning Settings LiteSpeed Cache [6] Tuning
•
Lazy Load Images: On
•
Lazy Load Images: On
•
Only Request WebP: On
•
Preserve EXIF data: Off*
Media Settings LiteSpeed Cache [7] Media
CDN LiteSpeed Cache [8] CDN
Results
GTmetrix https://gtmetrix.com/reports/14.wpjktmeetup.com/H0PnxvEu
Pingdom https://tools.pingdom.com/#!/b4mGjr/https://14.wpjktmeetup.com/
WebPageTest https://www.webpagetest.org/result/180512_E1_25d257eddf29ee1472bde608b6949f10/
Load Stress Test
1000 Requests / Min loader.io
2000 Requests / Min loader.io
5000 Requests / Min loader.io
10000 Requests / Min loader.io
Test on Slow Network
WebPageTest on Mobile with 3G Network https://www.webpagetest.org/result/180513_GC_c81a0a7201d2ea1ee94c24d91cc36c0e/
WebPageTest on Mobile with Slow 3G Network https://www.webpagetest.org/result/180513_ME_89a321ce83239742324d349807e1c384/
WordPress is Fast on Share hosting!
Disclaimer This results test is for demo and research purpose only. It’s running on real share hosting account and have demo content to match real life example as close as possible. The optimisation settings may or may not work for your site and may required tweaking based on your site conditions. The test results number may vary and I’m not guarantee that number for your sites. And if You decide to use this knowledge, do with your own risk. And please backup yours site before You start anything.
Q&A