Skip to main content
X-Ray is a CloudLinux PHP profiler. You point it at a URL on one of your domains, it captures the next handful of requests to that URL, and it reports back which function calls are responsible for the slow time. Closer to a flamegraph than a log dump. It’s the right tool when “the site is slow” and you need to know why, not just that it is.
X-Ray app with tracing tasks list and Start Tracing button

When to use it

  • A specific URL is slow. Not the whole site, just one page.
  • You’ve ruled out database connectivity (the Resource Usage IO column is fine) and want to know which PHP code is slow.
  • A plugin update broke performance and you can’t tell which one without measurement.
For account-wide resource pressure, look at Resource Usage instead. X-Ray is for tracing one URL pattern.

Start a trace

1

Click Start Tracing

Top-right of the page. The Start tracing dialog opens.
Start tracing dialog with Choose domain and Specify mask fields
2

Pick the domain

Click Choose domain and pick one of the domains on your account. X-Ray can only trace requests routed through the cPanel-managed PHP handler, so add-on and primary domains both work.
3

Specify the URL mask

The Specify mask field is the path you want to trace. Examples:
MaskMatches
/The homepage only
/checkoutExactly /checkout
/blog/*Anything under /blog/
/wp-admin/admin-ajax.phpExact admin-ajax handler
The How to use special characters? link in the dialog covers wildcards. * matches any path segment.
4

Pick how long to trace

Record for has two modes:
ModeWhat it doesWhen to use
RequestCapture the next N requests to the mask, then stop. Default 20.When you can hit the URL yourself or there’s predictable traffic.
Time intervalCapture every request to the mask for N hours, up to 48.When the slow page is rare and you don’t know when it’ll fire.
5

(Optional) Open Advanced settings

Tick the Advanced settings box for finer control. The most useful options:
  • Slow request threshold: only record requests that took longer than the threshold. Default is the system slow-request limit.
  • PHP version: trace only requests handled by a specific PHP version (useful when migrating).
6

Click Run

The task appears in the Tracing tasks list with status Running. Generate the traffic (refresh the URL, run the slow checkout, whatever it takes) until X-Ray’s collected enough samples.

Read the report

When the task finishes, click its row to open the report. The page shows three things:
  • Summary: average and slowest request times across the captured samples.
  • Function call list: a table of every PHP function called during the slow request, with cumulative time spent in each. Sortable by time-spent-descending; the worst offender ends up at the top.
  • Slow function flag: any function over a threshold gets a red dot. Click for the call stack that led to it.
A typical bad result looks like:
FunctionCallsTime
mysqli_query4124,820 ms
wp_cache_get1,103380 ms
apply_filters5,221220 ms
That tells you the page is making 412 queries, almost certainly an N+1 in a plugin. Time to dig into which call site is responsible.

What X-Ray can’t do

  • No view into MySQL internals. It tells you mysqli_query is slow, but not whether it’s the network, the query plan, or the locks. For that you need slow-query logs (open a ticket if you need them turned on).
  • No view into JavaScript or browser rendering. X-Ray is a server-side PHP profiler. Front-end performance needs Chrome DevTools or a real-user-monitoring tool.
  • No view into background jobs. Cron jobs, queue workers, and other non-HTTP PHP runs aren’t traceable through this UI.

Common gotchas

Either the URL mask doesn’t match any traffic, or the requests aren’t going through the PHP handler. Check by hitting the URL yourself in a browser; the task should pick it up within a few seconds. If the URL is served by a static cache (AccelerateWP page cache, Cloudflare cache, etc.) PHP is never invoked, so X-Ray sees nothing. Bypass the cache temporarily to trace.
Either the page actually isn’t slow under your test conditions (try a logged-in scenario, a cold cache, real DB load) or the slow-request threshold in Advanced settings is set too high. Lower the threshold to capture every request, then sort by time.
The Continuous tracing tab is available to administrators only on shared hosting. End-users can’t create continuous tasks. Workaround: set up a recurring tracing task (Time interval mode, 48 hours) and re-run it.
Either you already have a running task for that domain/URL, or an administrator-level continuous task is running. Wait for it to finish or check the Tracing tasks list and stop the existing one.

Need a hand?