Did you know the average user will wait only 2-3 seconds waiting for a webpage to load before abandoning it forever? Having a fast website is critical to its success. How do you ensure your site loads fast and reliably, to all kinds of users around the world? In this presentation we’ll discuss seven strategies for increasing your WordPress site’s speed.
Covering caching, content delivery networks, image optimization, file optimization, database cleaning, and hosting and theme choices, you’re guaranteed to leave this presentation with concrete next steps for improving your site’s performance:
Understand many components that go into determining site speed.
Use free tools to measure and monitor speed and performance of WordPress-based websites.
Create and modify websites to perform faster, better, stronger!
7 WAYS TO PUT YOUR WEBSITE ON THE FAST TRACK
#WCTO 2015 – MEAGAN HANES - @MHANES
15+ years coding websites
Started using WordPress in 2005
Works on sites as small as ants & as large as elephants
Favourite Colour: Rainbow!
Follow: @mhanes on Twitter
Why is speed important?
User Satisfaction & Audience Building
Slow site = unhappy users, won’t return
Affects your PageRank
Slow site = lower rank in Google, harder to be found
Impacts Sales and Success of Website
Slow site = higher abandonment rates, marketing dollars wasted
And many, many more reasons why…
Like bragging rights!!
Recipe: Speed Up Pie
Serves One Website
Pretty, but at what cost?
Not all themes are created equal!
Twenty Fifteen: 328KB, 13 files, 0.6s
Premium Themes: 850KB – 2.5MB, 40+ files, 1.5-3.0s
More features + plugins = more bloat
Be specific with your theme needs!
What can be done via plugins or functions.php?
Use a fast framework, or try a different theme
Measure, measure, measure!
GTMetrix, Pingdom, Webpagetest
More plugins, more problems
Each plugin you use adds overhead to your site.
Even admin-only plugins!
Get Data: P3 (Plugin Performance Profiler)
Don’t need it? Deactivate and delete it!
Add simple plugin functionality to functions.php
Turning off all comments, adding custom post types, etc
Disable plugins on unneeded pages – Plugin
Organizer by Jeff Sterup
May cause troubles, so test, test, test!
Advanced Coders: You can also load plugins via a
custom taxonomy + functions.php!1
File this under ‘u’ for ‘useful’
Remove unneeded whitespace, padding, simplify variable names
Makes code not easily readable by humans
BWP Minify Plugin
Wait to load JS until page is loaded
Achieve via BWP Minify or manually
<script source=“myScript.js” defer>
Google PageSpeed Insights = your best friend for more information
WARNING: Back up before playing with these!
Not all of us have high speed connections!
NEVER use images for text – unreadable by SEO!
Use only the image dimensions you need
Full Camera image size: 3000x2400 pixels, ~2MB
Common web size: 640x480, ~40KB
That’s over 50 times smaller!
Use the correct file type for your purpose
JPG: Rich Photos PNG: Vector/Transparency GIF: <256 Colours/Animated
Compress the file!
TinyPNG, TinyJPG, EZGIF
Refer to Google’s Image Optimization Guide1
Make it once, serve it over and over!
Serves static HTML vs dynamic database calls
Perfect for sites where content changes rarely
Also great when viewers won’t be logging in to see custom content
Many premium hosts (WPEngine) do this for you!
#1 caching plugin: WP Super Cache
“What about Queries?”
Transients API Query Caching1
No, it doesn’t stand for Canadian ;)
Deliver files from server closest to viewer
You wouldn’t order a pizza from another province, right?
Saves connection time, network hops
Distributes load when one server is overwhelmed
Best for when concurrent users, server stress is your bottleneck
Use them if it makes sense!
CloudFlare (free for basic accounts)
MaxCDN (what the pros use)
Oh yay, Spring Cleaning time!
More records = more time spent combing through them
Many are of no actual value:
Spam and unapproved comments
Old Page + Post Revisions
Items trashed but not purged
Leftover cruft from deleted plugins
Solution: WP-Optimize (https://wordpress.org/plugins/wp-optimize/)
Feeling brave? Play with phpMyAdmin!
WARNING: BACK UP FIRST!!
Don’t say I didn’t warn you.
Warp Speed, Captain!
Many factors influence site speed
Measure, Report, Improve!
Any step forward is a good step