Download - Ctrl+F5 Ahmedabad, 2017 - BOOST THE PERFORMANCE OF WORDPRESS WEBSITES by Pratik Jagdishwala
How to Boost the Performance of your WordPress-Powered Websites
PRATIK JAGDISHWALA
ABOUT ME
Why?
Why?● Very popular
● Easy to install, customize
● Simple to maintain
● Amazing community and
commercial support
● User friendly
Issues?
Issues?● Malware
● Vulnerabilities
● Bad practices
● Un-optimized/Un-secure
plugins/themes
● Too many addons
● Lack of long term
Slow Site Problems
● 1 Second Delay in Page load leads to
○ 11% Drop in pageviews
○ 16% Decrease in customer satisfaction
○ 7% Loss in Conversion
● 83% people expect a web page to load under 3 secs
● 40% will abandon a web page if it takes more than 3 secs to load
● 73% of mobile users have encountered a slow website
Solutions
Solutions● Adding more resources?
● VPS/Dedicated/Cloud?
● How much is too much?
● Where do you stop?
● What's the actual solution?
● Optimizations?
Optimizations
Optimizations● Analyze your website
○ Firebug (Mozilla)
○ PageSpeed
○ Yslow
○ Gtmetrix.com (Combination of Pagespeed, Yslow, etc)
Optimizations - Simple
Optimizations - Simple
● Update WP/Plugins/Themes to the latest version
● Enable auto updates
● Disable unnecessary plugins
● Limit Web Crawlers and Bots
● Limit WP Crons (Use cPanel or server side crons)
● Use reliable theme providers
● Avoid/Limit external scripts
Optimizations - Simple
● Use web optimized images (WP Smush)
● Use JPG instead of PNG
● No of elements < 30-50
● Page size guide
○ Excellent: Under 500 KB
○ Good: Under 1 MB
○ Acceptable: 1-3 MB
Optimizations - Advanced
● Use Domain Sharding
● Use CSS Sprites
● Customize wp-config
○ Autosave intervals
○ Limit post revisions
○ wp_home
○ wp_siteurl
Optimizations - Advanced
● WP-Sweep Plugin
○ Cleanup unused, orphaned and duplicate data
● WP-Optimize
● Anti Spambot plugin
● Expires and Etag for browsers
● Gzip on server
● MySQL caching
Optimizations - Advanced
● WP Super Cache or W3 Total Cache
● CDN’s
● Database caching
○ Memcached, Redis (DB caching)
● Web caching
○ Varnish caching
Optimizations - To Avoid
● Resource Intensive Plugins
○ Some SEO plugins
○ Some image galleries and media players
○ Web based backup plugins
○ Web based crons
● Pirated plugins/themes
● Scripts/plugins/themes from unknown/unreliable sources
Secure WP
Secure WP
● Secure wp-config
● No 777 perms
● Avoid unsecure FTP connections
● Use strong passwords
● Use Dual factor auth when possible
● Disable unused scripts
● Wordfence
Case Study
Case Study
● A simple blog set up on shared hosting in GPX Mumbai
● Multidomain Linux Hosting with cPanel
● Jmeter automated tests from Mumbai India
○ 1000 page requests
○ 5 concurrent threads
○ Every user requesting the page 200 times
● Page contains Multiple Images, Content, Comments
Pre Optimization
Pre-optimization setup
● Wordpress 4.7.2
● Plugins
○ Fakerpress
○ Akismet
○ Hello Dolly
● 1000 requests with 5 thread and 200 request per thread
● 2000 requests with 10 thread and 200 request per thread
Pre-optimization setup
Post Optimization (Phase 1)
Post-optimization (Phase 1)
● Wordpress 4.7.2
● Plugins
○ Fakerpress
○ Akismet
○ W3 Total Cache
○ WP Smush
○ WP Optimize
Post-optimization (Phase 1)
Post Optimization (Phase 2)
Post-optimization (Phase 2)
● Wordpress 4.7.2
● Plugins
○ Fakerpress
○ Akismet
○ W3 Total Cache
○ WP Smush
○ WP Optimize
Post-optimization (Phase 2)
Take away
Reach Out
[email protected]://twitter.com/pjagdishwala