Your SlideShare is downloading. ×
Optimizing WordPress -  WordPress SF Meetup April 2012
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Optimizing WordPress - WordPress SF Meetup April 2012

1,413

Published on

Published in: Technology
0 Comments
5 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
1,413
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
0
Comments
0
Likes
5
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. WordPressOptimization WordPress Optmization Ben Metcalfe | Co-founder, WP Engine @dotBen | ben@wpengine.com San Francisco WordPress Meetup – April 23rd 2012
  • 2. WordPressOptimization
  • 3. WordPressOptimization
  • 4. WordPressOptimization Before we begin…
  • 5. WordPressOptimization Why? • Um, why not? • Keep readers/customers happy! • Stay up under heavy load • Save $$$
  • 6. WordPressOptimization Level 1 Let‟s get the basics out the way :)
  • 7. WordPressOptimization Keep WP up to date Why wouldn‟t you?
  • 8. WordPressOptimization Caching plugins FTW!! W3-Total-Cache also: WPSuperCache, BatCache
  • 9. WordPressOptimization Deactivate unused plugins + delete plugins you don‟t use at all
  • 10. WordPressOptimization Avoid bad plugins Include (but not limited to) • backupwordpress • backwpup • broken-link-checker • dynamic-related-posts • file-commander • google-sitemap-generator • LinkMan (MyReviewPlugin Link Man) • MyRP (MyReviewPlugin) • wp-symposium-alerts
  • 11. WordPressOptimization Review your theme HTML • does it validate? • CSS at the top, JS at the bottom (not inline) PHP • Any weird code (if it looks bad, it probably is) • file_get_contents() / fgets()
  • 12. WordPressOptimization Is your host slow?
  • 13. WordPressOptimization Level 2
  • 14. WordPressOptimization Offloading (poor-mans CDN) Serve images via Flickr/etc
  • 15. WordPressOptimization Feedburn your RSS feed How many requests to your blog are /feed?
  • 16. WordPressOptimization Repair your MySQL DB Sometimes you need to tidy your room :) PHPMyAdmin, OptimizeDB, manually
  • 17. WordPressOptimization Load from multiple sub- domains good: foo1.yourdomain.com, foo2.yourdomain.com better: foo1.otherdomain.com, foo2.otheromain2.com
  • 18. WordPressOptimization Browser Caching HTTP Cache-Control Expires headers Entity Tags (W3-Total-Cache, WPSuperCache)
  • 19. WordPressOptimization Level 3 Mostly assumes SSH access
  • 20. WordPressOptimization Log slow MySQL queries Good HOWTO: http://hackmysql.com/nontech
  • 21. WordPressOptimization Check site with Profile Tools WP-Tuner WPDB Profiling http://speed.wpengine.com YSlow
  • 22. WordPressOptimization CDN MaxCDN (we use parent company @ WP Engine) Amazon CloudFront CloudFlare Use all the time or just „emergencies‟
  • 23. WordPressOptimization „Smush‟ your images WPSmush.it plugin
  • 24. WordPressOptimization Opcode cache, eg APC php-apc + W3-Total-Cache
  • 25. WordPressOptimization Apache optimizations Disable .htaccess, use httpd.conf
  • 26. WordPressOptimization Dedicated MySQLDB Box
  • 27. WordPressOptimization Level 4 Hitting the big time
  • 28. WordPressOptimization Reverse-proxy with nginx Run Apache on port 8080 Cache statics (good HOWTO on wp-performance.com)
  • 29. WordPressOptimization Varnish cache Save/server static pages to/from disk Ideally don‟t run Varnish on port 80, Avoid cookie issues
  • 30. WordPressOptimization Memcache Cache WordPress Object Cache Memcached plugin + PECL memcache extension Ideally run Memcache on separate box wp-memcached-manager – admin plugin
  • 31. WordPressOptimization HyperDB Replaces wpdb class Multiple database servers Replication + failover for redundancy Partitioning for scale
  • 32. WordPressOptimization Boss Level
  • 33. WordPressOptimization Static site on Amazon S3 “Movable Type” Model 100% Static site
  • 34. WordPressOptimization #Fails
  • 35. WordPressOptimization DON‟T edit core files! No matter what “performance” benefit you think it will make!
  • 36. WordPressOptimization Amazon EC2 … isn‟t a silver bullet
  • 37. WordPressOptimization Thank you! ben@wpengine.com http://wpengine.com
  • 38. WordPressOptimization Q&A or email: ben@wpengine.com

×