Getting Started

Deployment Deployment - Diagnose Migrations Staging

Site Management

Backups Client Reporting Passwords Plugin Automation Plugin Management - Global Plugins & Themes - Diagnose Plugins & Themes - General Plugins & Themes - Git Plugins & Themes - Logs Must Install White Label WordPress Updates

Caching & Performance

Caching Caching - Blogs/Articles Caching - Diagnose Caching - Git Caching - WooCommerce Redis Optimize & Scale

Security

Security Security - Firewall

SMTP, CDN & DNS

SMTP SendGrid CDN CDN - AWS CDN - Cloudflare CDN - Diagnose Domains & DNS

Server & Tools

Analytics & Logs CRON Jobs Database Debug Tool Git Monitoring PHP Settings Redirects SEO Tools Server Errors sFTP SSL

Staq Billing

Staq Billing > Account Staq Billing > Client Staq Billing > Setup

Media

Media Media - Diagnose Media - Optimize

Accounts & Billing

Accounts & Billing

General

WordPress Hosting Website Diagnose Troubleshoot - Other

How to Speed Up the Backend of WordPress & AJAX requests


On this page

    Below, is a guide on how to:

    • improve the speed of the WordPress backend
    • improve the speed of AJAX requests.

    By improving and optimizing both the backend and AJAX requests will greatly enhance your site’s overall speed, efficiency and user experience.

    Simple AJAX Test

    Before you go through the process of improving AJAX and PHP execution, go to your WordPress site on Staq and then click Staq Hosting > Advanced > Monitor and click Test AJAX and then note the execution time:

     

    Once you’ve recorded down the actual execution time, here’s how you can speed up both the backend and AJAX requests of your WordPress site.

    Advanced Test: Staq Query Monitor

    If you wish to understand the execution times of how queries interact with your website, you can enable Staq’s query monitoring tool by going to Staq Hosting > Advanced > Monitor and click Enable monitor. For more information, visit how to debug slow WordPress queries knowledge base.

    Solutions

    1. Unoptimized Database

    Database bloat can lead to a multitude of issues, including inefficient SQL queries, slower website loading speeds, longer backup times, unnecessary consumption of storage space, and even service outages or data loss due to excessive resource utilization.

    How to Address Database Bloat:

    We recommend using the Advanced Database Cleaner plugin. This is a database optimization tool that clears out unneeded data, like expired transients and orphan post metadata. While it can do much more, it’s an effective way of cleaning up your database if it’s bloated.

    In addition, check for large database tables, such as wp_woocommerce_log. If you notice that a specific table is of a significant size, try to understand why. You may be able to clear or delete the entries, further reducing your database size.

    2. Enable Redis Object Caching

    Enabling Redis Object Caching can also significantly improve your backend performance. Redis is an in-memory data structure store, used as a distributed, in-memory key-value database, cache and message broker, with optional durability. Redis allows you to alleviate database load and speed up your WordPress website.

    To enable Redis Object Caching on your Staq WordPress site, follow the guide on our knowledge base: Enable Redis Object Caching.

    3. Upgrade to PHP 8.2

    Upgrading your PHP version can also enhance your site’s performance. PHP 8.2 comes with numerous improvements and new features that can accelerate your WordPress backend.

    To upgrade to PHP 8.2 on your Staq WordPress site, check out our guide: Upgrade to PHP 8.2.

    By taking these steps to optimize your database, enable Redis Object Caching, and upgrade to PHP 8.2, you can significantly improve the speed and performance of your WordPress site’s backend. As a result, you’ll enjoy a smoother, faster, and more efficient website.

    4. Update Plugins/Theme

    It is crucial to ensure that your plugins and theme is using the latest version. By maintaining your plugins, this can improve the overall speed of your website.

    It is also recommended that you:

    • review your existing plugins and deactivate and delete all plugins that aren’t required
    • delete deactivated plugins

    By maintaining a minimal set of plugins will maximise the speed and reduce the security issues down the track.

    5. AJAX optimization

    Out of the box, Staq automatically optimizes your AJAX requests. Just in case, the settings appear in Staq Hosting > Advanced > Heatbeat API. By default, Staq sets this at 120 seconds. If it is set on this value, then it is recommended to keep it on this value.

    Need some help?

    We all do sometimes. Please reach out to our support team by dropping us a support ticket. We will respond fast.