When it comes to making your Drupal site faster there are two main areas of focus: performance and scalability.
Performance is how fast a single page can be served. This is affected by things like how long it takes your code to execute, the speed of the required database queries, settings in your web server, and other bottlenecks in the process of servicing a single request. Your best bet for improving this is ensuring proper configuration of modules. Then use a profiler to locate bottlenecks in your code. Either optimize them, cache the result to eliminate repeat processing, or both. Performance applies to the front-end of your site as well: the HTML, CSS and JavaScript impacts the performance of the user’s browser.
Scalability refers to how many concurrent pages your site can serve without adversely affecting performance. This is affected by limitations like how many requests the server can handle before it slows down, and considerations in Drupal’s code that allow for mitigating these limitations. It can be improved by making changes to your infrastructure that increase its ability to handle more requests quickly.
Example tasks
- Configure Drupal core and contributed modules for optimal performance
- Test a site’s performance and ability to handle multiple concurrent users
- Make a Drupal site faster by using various caching systems like Varnish, Redis, and a CDN
Confidence
Our tutorials are up-to-date. There are other topics related to performance and scalability that we have not covered and are a work in progress. See the external resources for additional guidance on this subject.
Drupalize.Me resources
External resources
-
BigPipe module (Drupal.org)
- Documentation guide for BigPipe core module.
-
High Performance Drupal (youtube.com)
- This presentation by Jeff Geerling does a great job of outlining a process for improving Drupal’s performance and some of the common approaches to doing so. Note: PHP 7 is now the recommended version for use with Drupal 8 even though the video mentions 5.5+.
-
Drupal Performance Tuning (youtube.com)
- This presentation by Lesmana Lim contains good information about tuning Drupal and various commonly used contributed modules for performance. It’s worth watching to give you an idea of the types of things to look for, even if the specifics are different for your site.
-
Drupal Performance Optimization Checklist (redcrackle.com)
- A long list of things to consider when optimizing a Drupal site including configuration options, contributed modules, and non-Drupal tools
-
High Performance Drupal by Jeff Sheltren, Narayan Newton, Nathaniel Catchpole (shop.oreilly.com)
- This book, written by some of the most experienced Drupal performance consultants, is a great resource for information on tuning Drupal and all the parts of the LAMP stack. Especially useful if you’re maintaining your own infrastructure.
-
Common max-age Pitfalls When Working with Drupal's Page Cache (lullabot.com)
- Learn about time-based caching and how to implement it while avoiding common pitfalls.
-
Making Legacy Sites More Performant with Modern Front-End Techniques (lullabot.com)
- Learn from a case study on how to optimize the front-end for higher performance.
-
Modern Decoupling is More Performant (lullabot.com)
- Learn about the subtleties of designing proper APIs to maximize performance and minimize round trips to the server.
- Incredible Decoupled Performance with Subrequests (lullabot.com)
- Learn about how to use the Subrequests module to aggregate a set of requests.
- Drupal 7: Managing site performance and scalability (drupal.org)
- This series of articles will demonstrate how a Drupal 7 site can be configured for optimal performance.