How to Use X‑Ray to Diagnose Slow WordPress Performance
For iCoreHosting cPanel & DirectAdmin (CloudLinux) • Works best with LiteSpeed Web Server + LiteSpeed Cache
1) Before you begin
- Ensure your hosting plan is on CloudLinux (all iCoreHosting shared/reseller hosting are) and you’re using PHP 8.1+ when possible.
- Have your WordPress admin login ready so you can reproduce slow actions (e.g., editing, WooCommerce checkout).
- Keep the trace short (2–5 mins) and reproduce the problem once or twice to keep results clean.
- If you can’t locate X‑Ray in your control panel, contact Support.
2) Start an X‑Ray trace (cPanel)
- Log in to cPanel.
- Under Software, click X‑Ray App.
- Click Start Tracing.
- Select the domain (and path, if needed). Choose Trace Type = URL and input the exact page that’s slow (e.g.,
/checkout). - Leave the trace running and reproduce the slowness on your site (frontend and/or wp‑admin).
- Return to X‑Ray and click Stop to generate the report.
3) Start an X‑Ray trace (DirectAdmin)
- Log in to DirectAdmin.
- Open Extra Features → X‑Ray (or search for “X‑Ray” in the top search bar).
- Click Start Tracing, choose your domain/path and URL to monitor.
- Reproduce the slow action for ~2–5 minutes.
- Click Stop and open the generated report.
4) Read the X‑Ray report
A) Wall Time (Total Time)
Overall duration per request. > 1s for common pages is a red flag.
B) PHP Script Timeline
Shows which plugin/theme files consumed time. Sort by Time or Calls to find top offenders.
C) MySQL Queries
Look for slow SELECT with meta tables, missing indexes, or huge COUNT(*) scans.
D) External Calls
API calls to payment/shipping/CRM/CDN. Network wait can dominate wall time.
5) Common findings & quick fixes
- Large processing in a plugin → Update it, disable unused modules, or replace with a lighter alternative.
- Page builders loading too much → Enable LiteSpeed Cache (LSCache) and minify/combine CSS/JS.
- WooCommerce slow on Cart/Checkout → Reduce real‑time stock/price/3rd‑party calls; cache fragments when safe.
- wp_postmeta / wp_options bloat → Use WP‑Optimize to clean transients/revisions; reduce autoloaded options.
- Repeated LIKE '%keyword%' scans → Replace search with Relevanssi or add specific indexes (developer task).
- COUNT(*) on large tables → Use cached counts or pagination strategies.
- Payment/shipping/CRM lookups → Cache responses briefly when possible; defer non‑critical calls to background jobs.
- 3rd‑party fonts/maps/social embeds → Load async/defer; consider locally hosting critical assets.
- Hitting LVE (CPU/IO/memory) ceilings during spikes? Optimize + scale up. For sustained load, consider VPS/Dedicated.
- Large media or backup plugins can saturate I/O → Exclude archives from on‑site backups; offload to remote.
6) After tracing: harden & optimize
- Enable LiteSpeed Cache (LSCache) plugin for WordPress. Turn on page cache, browser cache, and CSS/JS optimization. Use QUIC.cloud CDN if suitable.
- Image optimization: convert to WebP/AVIF, lazy‑load below‑the‑fold images.
- DB cleanup: remove transients, revisions; keep autoloaded options small. Schedule periodic DB maintenance.
- Object Cache (if available): enable Redis/Memcached via your plan or consider upgrading to a VPS for dedicated caching.
- Monitor: Re‑run X‑Ray after each change to validate impact. Keep traces short and focused on one change at a time.
7) FAQ
Why don’t I see X‑Ray in my panel?
Is there any risk to running X‑Ray?
My site is still slow after fixes—what next?
8) Need help?
Include: domain, sample slow URL(s), timeframe of slowness, and what actions you took.
