PHPackages                             bastibuck/contao-ab-testing - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Testing &amp; Quality](/categories/testing)
4. /
5. bastibuck/contao-ab-testing

ActiveContao-bundle[Testing &amp; Quality](/categories/testing)

bastibuck/contao-ab-testing
===========================

A/B testing with Contao Open Source CMS

3.0.0(5y ago)89782[1 issues](https://github.com/bastibuck/contao-ab-testing/issues)LGPL-3.0-or-laterPHP

Since Jul 1Pushed 5y ago1 watchersCompare

[ Source](https://github.com/bastibuck/contao-ab-testing)[ Packagist](https://packagist.org/packages/bastibuck/contao-ab-testing)[ Docs](https://github.com/bastibuck/contao-ab_testing)[ RSS](/packages/bastibuck-contao-ab-testing/feed)WikiDiscussions master Synced 2d ago

READMEChangelog (1)Dependencies (1)Versions (15)Used By (0)

Contao: A/B Testing
===================

[](#contao-ab-testing)

[![Latest Stable Version](https://camo.githubusercontent.com/3d3c8e3c9f2e51be71452cb48a33a388fe2c5bcd53598d676ff3bac5820543d9/68747470733a2f2f706f7365722e707567782e6f72672f62617374696275636b2f636f6e74616f2d61622d74657374696e672f762f737461626c65)](https://packagist.org/packages/bastibuck/contao-ab-testing)[![Total Downloads](https://camo.githubusercontent.com/adb00343c1361e52690eaf3b80a1ef9c33444bf3678a2af8df2bb85554fe5d5d/68747470733a2f2f706f7365722e707567782e6f72672f62617374696275636b2f636f6e74616f2d61622d74657374696e672f646f776e6c6f616473)](https://packagist.org/packages/bastibuck/contao-ab-testing)[![License](https://camo.githubusercontent.com/566ec8875c2a75cc9876d5d82981a878d681a1e52ea19ef0263f4cb62d689a9e/68747470733a2f2f706f7365722e707567782e6f72672f62617374696275636b2f636f6e74616f2d61622d74657374696e672f6c6963656e7365)](https://packagist.org/packages/bastibuck/contao-ab-testing)

This extension provides a new page type to evenly split up visitor traffic between the selected test-pages. At the same time it makes sure that returning visitors will be shown the same page they have visited before.

This way A/B tests can be performed in Contao Open Source CMS.

Features
--------

[](#features)

- Select one or more pages to be tested
- test pages are rendered within the the new page type so all versions have the same url
- Set a cookie and its' expiring time to identify returning visitors
- adds a new Content Element to set a Matomo Custom Variable easily

Notice
------

[](#notice)

This extension **doesn't** provide analytics! To get insights on statistics of your visitors you will need to use an analytic software like Google Analytics, Matomo or similar.

How does the extension work?
----------------------------

[](#how-does-the-extension-work)

[![A/B Testing visitor flow](../screens/AB-Test-Extension.jpg)](../screens/AB-Test-Extension.jpg)

The visitor flow is visualized in the graphic above and shows how the extension works.

1. Visitor **a** is the first visitor to our A/B test. The A/B test page checks which test-page was last visited by any visitor. Since visitor **a** is the first visitor there will be no result and **a** will be rendered the first of the test-pages **V0**.
2. Visitor **b** is the second visitor. Checking which page was rendered before will now return the ID of test-page **V0**. Therefore visitor **b** will be given the second test-page **V1**.
3. When visitor **c** visits our A/B test the check of the last visited page will return the ID of the second page **V1** since the last visitor was shown this one. Visitor **c** will therefore be rendered test-page **V0** again as **V1** was the last page in the test.
4. Visitor **d** is a returning visitor. He visited the A/B test before and was given **V0**. By this time a cookie was saved on his device containing the value of the test-page he got to see. On the returning visit the A/B test checks if the cookie exists and if so gets its' value and renders the same page he has seen before. In this case this will also be **V0** although the next page to be visited would be **V1** again (if it wasn't a returning visitor). Additionally the last visited pge won't be saved in the case of returning visitors so the regular visitor order won't be messed up.
5. Visitor **e** is a first time visitor, has no cookie with a page ID value and therefore triggers the check of the last visited page which returns the ID of page **V0** (visitor **c** was the last one to visit it). Therefore visitor **e** will be shown test-page **V1**.

###  Health Score

33

—

LowBetter than 75% of packages

Maintenance18

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity71

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~103 days

Recently: every ~305 days

Total

13

Last Release

2001d ago

Major Versions

1.1.3 → 2.0.02018-02-08

2.0.0 → 3.0.02020-11-19

### Community

Maintainers

![](https://www.gravatar.com/avatar/c38cc3c3ddcfb9a637c41c1d27a3a4f0c7f8c99865008829d3342dd1b0e7e19c?d=identicon)[bastibuck](/maintainers/bastibuck)

---

Top Contributors

[![bastibuck](https://avatars.githubusercontent.com/u/6306291?v=4)](https://github.com/bastibuck "bastibuck (52 commits)")

---

Tags

ab-testinganalyticscontaoconversionsplit-testingvisitortestinglanding pageab testab-testingconversion-rateABlandingpageonline marketing

### Embed Badge

![Health badge](/badges/bastibuck-contao-ab-testing/health.svg)

```
[![Health](https://phpackages.com/badges/bastibuck-contao-ab-testing/health.svg)](https://phpackages.com/packages/bastibuck-contao-ab-testing)
```

###  Alternatives

[phpunit/phpunit

The PHP Unit Testing framework.

20.0k910.7M134.8k](/packages/phpunit-phpunit)[phpunit/php-code-coverage

Library that provides collection, processing, and rendering functionality for PHP code coverage information.

8.9k892.4M1.5k](/packages/phpunit-php-code-coverage)[mockery/mockery

Mockery is a simple yet flexible PHP mock object framework

10.7k497.0M23.6k](/packages/mockery-mockery)[behat/behat

Scenario-oriented BDD framework for PHP

4.0k96.8M2.0k](/packages/behat-behat)[symfony/phpunit-bridge

Provides utilities for PHPUnit, especially user deprecation notices management

2.5k201.2M4.2k](/packages/symfony-phpunit-bridge)[brianium/paratest

Parallel testing for PHP

2.5k118.8M754](/packages/brianium-paratest)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
