Back to Blog
Magento

10 Magento 2 Performance Optimisation Tips for 100/100 PageSpeed

Learn proven techniques to optimize your Magento 2 store for perfect PageSpeed scores, including caching strategies, image optimisation, and code improvements.

Chris Astley
Web Development Expert
10 Magento 2 Performance Optimisation Tips for 100/100 PageSpeed

Achieving a 100/100 PageSpeed score with Magento 2 might seem impossible, but with the right optimisations, it’s absolutely achievable. Here are my top 10 tips based on real-world implementations.

1. Implement Full Page Cache (FPC)

Full Page Cache is your first line of defense against slow page loads. Configure Varnish properly:

bin/magento config:set system/full_page_cache/caching_application 2
bin/magento setup:config:set --http-cache-hosts=varnish

2. Optimize Images with WebP

Convert all product images to WebP format for 30% smaller file sizes:

  • Use Magento’s built-in image optimisation
  • Implement lazy loading for below-the-fold images
  • Set proper image dimensions to prevent layout shift

3. Consider Hyvä Themes

Hyvä Themes is a game-changer for Magento performance:

  • 90% less JavaScript compared to Luma
  • Alpine.js instead of Knockout.js and jQuery
  • Tailwind CSS for minimal CSS footprint
  • Native 100/100 PageSpeed scores out of the box

4. Database Optimisation

Regular database maintenance is crucial:

  • Clean log tables regularly
  • Optimize flat catalog tables
  • Use Redis for session storage
  • Enable query caching

5. Enable Production Mode

Always run production stores in production mode:

bin/magento deploy:mode:set production

6. Configure Redis Caching

Redis significantly improves cache performance:

'cache' => [
    'frontend' => [
        'default' => [
            'backend' => 'Cm_Cache_Backend_Redis',
            'backend_options' => [
                'server' => '127.0.0.1',
                'port' => '6379',
                'database' => '0'
            ]
        ],
        'page_cache' => [
            'backend' => 'Cm_Cache_Backend_Redis',
            'backend_options' => [
                'server' => '127.0.0.1',
                'port' => '6379',
                'database' => '1'
            ]
        ]
    ]
]

7. Optimize CSS Delivery

  • Inline critical CSS for above-the-fold content
  • Defer non-critical styles
  • Remove unused CSS
  • Minimize CSS files in production

8. Implement CDN

Use a CDN for static content delivery:

  • CloudFlare for global distribution
  • Configure proper cache headers
  • Implement image optimisation at CDN level
  • Enable HTTP/2 and Brotli compression

9. Elasticsearch Configuration

Optimize search performance:

  • Use Elasticsearch 7.x or higher
  • Configure proper index settings
  • Implement search result caching
  • Optimize synonym and stopword configuration

10. Regular Performance Monitoring

Continuous monitoring identifies bottlenecks:

  • Use New Relic or Blackfire for profiling
  • Monitor slow queries with MySQL slow query log
  • Track Core Web Vitals
  • Set up automated PageSpeed tests

Results You Can Expect

After implementing these optimisations, you can expect:

  • 90+ PageSpeed scores on mobile
  • 100/100 scores on desktop
  • 50% reduction in server response time
  • Improved Core Web Vitals
  • Better search engine rankings
  • Higher conversion rates

Need Help?

Optimizing Magento performance requires expertise and experience. If you need help achieving 100/100 PageSpeed scores for your Magento store, I’m here to help.

Contact me for a free performance audit and consultation.

Tags

Magento 2 Performance PageSpeed SEO E-commerce

Need Help With Your Project?

Let's discuss how I can help bring your web development ideas to life

Get in Touch