- Make Fewer HTTP Requests
- Put Stylesheets at the Top
- Put Scripts at the Bottom
- CSS Sprite
- Load Asynchronous Scripts file
- Optimize Images:
- Compress image
- Resize image
- Load progressive
- Size specific, don’t scale
-
Database
- Indexes
- Avoid (N+1) query
- Batch loading
- Transaction
-
Caching:
- Fragment caching
- Query caching
- Redis caching
-
Run big process in background jobs
-
Use DNS: To serve images, assets (Sharding Dominant Domains)
-
Upgrade Rails, update gems, reduce gem.
- Add an Expires Header
- Gzip Components
- Using Proxy to Cache on Nginx
- Config Worker
- HTTP2
- New Relic
- Pingdom
- PageSpeed Insight: https://developers.google.com/speed/pagespeed/insights
- GTmetrix: https://gtmetrix.com
- WebPageTest: https://www.webpagetest.org
- Pingdom: https://www.pingdom.com
- Book:
- High Performance Web Sites
- Even Faster Web Sites: Performance Best Practices for Web Developers
- PageSpeed Insights Rules: https://developers.google.com/speed/docs/insights/rules
- Best Practices for Speeding Up Your Web Site: https://developer.yahoo.com/performance/rules.html
- Tuning NGINX for Performance: https://www.nginx.com/blog/tuning-nginx/
- 5 Tips to Speed up Your Website: http://luanotes.com/posts/5-tips-to-speed-up-your-website
- Frontend performance checklist: https://www.smashingmagazine.com/2018/01/front-end-performance-checklist-2018-pdf-pages/
- Progressive image loading: https://blog.botreetechnologies.com/page-load-optimization-by-progressive-image-loading-like-medium-1d0f94744a4d
- https://www.railsspeed.com
- https://www.speedshop.co/blog