Up until now, Croct's official SDKs have been heavily focused on the JavaScript ecosystem. While client-side and edge-rendered architectures are incredibly popular, a massive portion of the web relies on robust PHP backends.
Today, we are thrilled to announce that we are bringing our native, real-time optimization engine directly to the server-side with four new SDK releases: PHP, Laravel, Symfony, and Drupal.
These new packages give backend developers the tools they need to fetch dynamic content and evaluate Contextual Query Language (CQL) rules on the server-side, delivering tailored experiences without sacrificing performance or caching efficiency.
Here is what you need to know about integrating Croct into your PHP ecosystem.
Server-side dynamic content with smart caching
One of the most complex challenges in server-side personalization and AB testing is managing shared caches, such as CDNs, Varnish, and reverse proxies. A shared cache stores one copy of a response and serves it to everyone, which doesn't work for dynamic pages. If a visitor's tailored content were stored in a shared cache, the next visitor would receive the exact same version.
Our new integrations are built to prevent this automatically.
Whenever a response depends on the visitor, whether you fetched personalized content, evaluated a query, or identified the user, the SDK automatically marks the response as private. This standard Cache-Control: private directive ensures that shared caches skip the dynamic content response, while pages that render only static content remain highly cacheable.
We have also tailored the caching mechanisms to fit seamlessly into each framework:
- Drupal: The Croct module automatically adds the session cache context to your render array, ensuring Drupal's internal render and dynamic page caches vary per visitor.
- Symfony: The bundle supports Edge Side Includes (ESI) out of the box. This allows you to cache the static shell of the page on your shared cache and pull the personalized section in as a separate, uncached fragment on every request.
Seamless client and server synchronization
Personalization is a full-stack effort. While the PHP SDK runs on the server to fetch content and evaluate queries, you still need to track user interactions (like clicks and conversions) in the browser.
To connect the frontend and backend into a single visitor session, our SDKs make it incredibly easy to configure the client-side JavaScript SDK using your server configuration.
For example, in a pure PHP setup, calling Croct::emitCookies() writes the session cookies before any output, while getPlugOptions() returns the application ID and cookie configuration needed for the JavaScript SDK. This ensures the browser works transparently with the exact same visitor and client ID.
Flexible rendering paths
We understand that every page has different performance requirements. Our PHP SDKs give you total flexibility over how you handle dynamic content for personalization and AB testing:
- Personalize on the server: Fetch content in your controller. The page loads instantly with the final content, eliminating client-side flicker and keeping the content fully visible to crawlers.
- Personalize on the client: If you need a specific page to remain in the shared cache, you can render a default static HTML shell on the server and use the Croct browser SDK to personalize it on the client.
From personalization and experimentation to content and data management, we have all you need to deliver better user experiences.

Get started in seconds
Just like our JavaScript SDKs, integrating Croct into your PHP applications is streamlined and fast. You can initialize your project using our CLI by simply running npx croct@latest init.
Whether you are building a custom PHP application, scaling a Laravel SaaS, or managing a large-scale Drupal or Symfony project, you now have the tools to deliver high-performance personalization natively.
Check out the full documentation and start building today.