A WordPress AI workload used 27 seconds of PHP time
A WordPress AI workload for creating one featured image consumed about 27.36 cumulative seconds of PHP processing time in a Kinsta test published on October 22, 2026. PHP is the software WordPress uses to run dynamic requests, and a PHP worker is one server process available to handle such work. The measurement matters because each worker involved in a synchronous AI request remains occupied while an external model processes and returns its response.
WordPress can interact with artificial intelligence through crawler traffic, plugins using the AI Client, and external applications querying the Abilities API. An API, or application programming interface, is a defined way for software systems to exchange requests and results. WordPress provides the Abilities API for exposing actions that software can invoke, while the AI Client routes work to a selected AI provider. Operations such as image generation and audio transcription can take several seconds, reducing the worker capacity available to visitors and other automated requests during that period.
Kinsta tested the official WordPress.org AI plugin with a configured Google connector. The process required an API key from the provider, activation of that provider under Settings > Connectors, and installation of the AI plugin. The plugin registered abilities including Image Generation and Editing, visible under Tools > Abilities Explorer. A new post was then created, and its Generate featured image control started the workflow. Kinsta noted that its examples were recorded at different times, so the timings vary between the monitoring views. Results also depend heavily on provider response time and the plugin's own processing.
The server analysis used Kinsta APM and access logs. APM means application performance monitoring, which records where an application spends its execution time. Kinsta says customers can enable its tool under Sites > sitename > APM, select a monitoring period, and later inspect transactions, plugins, themes, WordPress hooks, slow database queries and external requests. An access log is the web server's record of incoming requests, including the requesting IP address and User Agent, requested address, status code and total execution time. Kinsta exposes access, cache and error logs through its dashboard and also permits log downloads through its file-management and remote-access tools.
During one two-minute APM window, PHP execution totaled about 27 seconds, the database server used 271 milliseconds, and external transactions accounted for more than 19 seconds. Requests to the /wp-json address, used by the WordPress REST API, were the slowest transactions. A REST API is a web interface through which software requests data or actions. The ai-provider-for-google and ai plugins together represented nearly 90% of the recorded duration.
External-request data showed that POST requests to generativelanguage.googleapis.com accounted for 95.51% of all external transaction time, while GET requests to the same service represented 3.94%. POST requests send data for processing, while GET requests retrieve a resource. The POST calls accumulated more than 18 seconds. Kinsta's APM distinguishes total duration, the sum across every call to an endpoint, from maximum and average sample duration. It also reports the average execution rate per minute, so total duration should not be mistaken for the length of one request.
The transaction trace exposed the execution path behind image generation. WordPress started through wp-blog-header.php, and WP_REST_Server dispatched the request. Generate_Image.php invoked generate_image in the WordPress AI image namespace, class-wp-ability.php passed execution to WP_AI_Client, and PromptBuilder.php assembled the instructions. GoogleTextGenerationModel.php converted them into a Gemini-compatible request. HttpTransporter.php then passed the call through the WordPress HTTP API to WP_Http->request. This opened a synchronous, blocking connection, meaning the same PHP worker waited for Google rather than becoming available for another job. One traced request occupied its worker for more than eight seconds. APM also provided a stack trace, a file-by-file and line-by-line record of the PHP code executed.
The access logs showed four sequential Abilities API operations. Prompt generation sent the post content to Gemini and took 5.432 seconds. Image generation sent the resulting description to Google's Imagen model and waited 9.795 seconds for the binary or base64 image payload, a text representation of the image data. Alt-text generation then asked Gemini to analyse the image and took 11.305 seconds. Finally, image import downloaded the payload and registered it in the WordPress Media Library in 0.839 seconds. A subsequent GET request fetched the finished JPEG from the uploads directory with 0.000 seconds of PHP time because the web server delivered the static file without running WordPress. Rounded to the figures presented in the analysis, the four PHP operations totaled 27.36 seconds.
Browser developer tools offered a separate client-side view. After opening the Network panel and filtering for background web requests, Kinsta recorded 5.52 seconds for prompt generation, 9.92 seconds for image generation, 7.32 seconds for alt text and 1.79 seconds for image download, cropping and Media Library registration. That produced a total browser wait of 24.55 seconds. These numbers differ from the server-log measurements because the operations were performed at different times, not because the two views measure an identical run.
The test does not establish a fixed cost for every AI feature, but it demonstrates the method and the capacity risk. Several overlapping blocking jobs can occupy the available PHP workers, increase queues and latency, and raise the likelihood of timeouts, HTTP 5xx server errors or downtime. Kinsta concluded that two or three simultaneous tasks could saturate a traditional setup with limited resources, although the actual threshold depends on the site's worker allocation, traffic, code and provider response times. Bandwidth can also rise when image payloads are transferred.
Site owners should repeat this measurement in a staging environment, which is a private copy used for testing, and inspect both server traces and browser timings before deploying an AI feature to a busy production site. Infrastructure with caching, database optimisation and scalable worker capacity cannot remove an external model's processing delay, but it can provide more room for concurrent requests. For organisations that want hosting handled as a managed service, AEU Hosting provides managed WordPress hosting secured end to end.