PHPackages                             snowplow/referer-parser - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. snowplow/referer-parser

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

snowplow/referer-parser
=======================

Snowplow Refer(r)er parser for PHP

0.2.0(10y ago)3832.3M↓66.3%150[32 issues](https://github.com/snowplow/referer-parser/issues)20MITCI passing

Since Feb 1Pushed 4w ago33 watchersCompare

[ Source](https://github.com/snowplow/referer-parser)[ Packagist](https://packagist.org/packages/snowplow/referer-parser)[ RSS](/packages/snowplow-referer-parser/feed)WikiDiscussions master Synced 2d ago

READMEChangelog (10)Dependencies (2)Versions (2)Used By (20)

referer-parser
==============

[](#referer-parser)

referer-parser is a database for extracting marketing attribution data (such as search terms) from referer URLs, inspired by the [ua-parser](https://github.com/tobie/ua-parser) project (an equivalent library for user agent parsing).

The referer-parser project also contains multiple libraries for working with the referer-parser database in different languages.

referer-parser is a core component of [Snowplow](https://docs.snowplow.io/docs/).

*Note that we always use the original HTTP misspelling of 'referer' (and thus 'referal') in this project - never 'referrer'.*

Database
--------

[](#database)

The database is available in YAML and JSON format and is hosted in a public S3 bucket. The right file to use depends on which version of Snowplow Enrich you are running.

### If you are on Snowplow Enrich 5.3 or later

[](#if-you-are-on-snowplow-enrich-53-or-later)

Use the `referers-5.3` file. This is the actively-maintained database, updated daily. It includes all referer categories including `chatbot`.

```
https://s3-eu-west-1.amazonaws.com/snowplow-hosted-assets/third-party/referer-parser/referers-5.3.yaml
https://s3-eu-west-1.amazonaws.com/snowplow-hosted-assets/third-party/referer-parser/referers-5.3.json

```

### If you are on Snowplow Enrich earlier than 5.3

[](#if-you-are-on-snowplow-enrich-earlier-than-53)

Use the `referers-latest` file. This file is frozen at its July 2025 state and will never be updated, ensuring that deployments on older versions of Enrich continue to work without any risk of breakage. It does not include `chatbot` entries or any referers added after July 2025.

```
https://s3-eu-west-1.amazonaws.com/snowplow-hosted-assets/third-party/referer-parser/referers-latest.yaml
https://s3-eu-west-1.amazonaws.com/snowplow-hosted-assets/third-party/referer-parser/referers-latest.json

```

### Version numbering

[](#version-numbering)

The version number in the filename (e.g. `5.3`) refers to the minimum version of Snowplow Enrich required to parse that file. If a future change to the database requires a newer version of Enrich, a new versioned file will be introduced at that point (e.g. `referers-9.9`) and the previous versioned file will be frozen.

### Date-stamped snapshots

[](#date-stamped-snapshots)

Each day's database is also archived with a date stamp. These follow the current format and therefore also require Enrich 5.3 or later.

```
https://s3-eu-west-1.amazonaws.com/snowplow-hosted-assets/third-party/referer-parser/referers-YYYYMMDD.yaml
https://s3-eu-west-1.amazonaws.com/snowplow-hosted-assets/third-party/referer-parser/referers-YYYYMMDD.json

```

Example:

```
https://s3-eu-west-1.amazonaws.com/snowplow-hosted-assets/third-party/referer-parser/referers-20260531.yaml
https://s3-eu-west-1.amazonaws.com/snowplow-hosted-assets/third-party/referer-parser/referers-20260531.json

```

Language-specific repositories
------------------------------

[](#language-specific-repositories)

- Scala:
- Java:
- Ruby:
- Python:
- NodeJS:
- .NET:
- PHP:
- Golang:
- Erlang:

referers.yml
------------

[](#referersyml)

referer-parser identifies whether a URL is a known referer or not by checking it against the [`referers.yml`](https://github.com/snowplow-referer-parser/referer-parser/blob/master/resources/referers.yml) file; the intention is that this YAML file is reusable as-is by every language-specific implementation of referer-parser.

The file is broken out into sections for the different mediums that we support:

- `unknown` for when we know the source, but not the medium
- `email` for webmail providers
- `social` for social media services
- `search` for search engines

Then within each section, we list each known provider (aka `source`) by name, and then which domains each provider uses. For search engines, we also list the parameters used in the search engine URL to identify the search `term`. For example:

```
Google: # Name of search engine referer
  parameters:
    - 'q' # First parameter used by Google
    - 'p' # Alternative parameter used by Google
  domains:
    - google.co.uk  # One domain used by Google
    - google.com    # Another domain used by Google
    - ...
```

The number of referers and the domains they use is constantly growing - we need to keep `referers.yml` up-to-date, and hope that the community will help!

Contributing
------------

[](#contributing)

We welcome contributions to referer-parser:

1. **New search engines and other referers** - if you notice a search engine, social network or other site missing from `referers.yml`, please fork the repo, add the missing entry and submit a pull request
2. **Bug fixes, feature requests etc** - much appreciated!

See the [Snowplow contributing guidelines](https://docs.snowplow.io/docs/contributing/) for more details.

Copyright and license
---------------------

[](#copyright-and-license)

`referers.yml` is based on [Matomo's](https://matomo.org) `SearchEngines.php` and `Socials.php`, copyright 2012 Matthieu Aubry and available under the [GNU General Public License v3](http://www.gnu.org/licenses/gpl-3.0.html).

###  Health Score

57

—

FairBetter than 98% of packages

Maintenance60

Regular maintenance activity

Popularity63

Solid adoption and visibility

Community45

Growing community involvement

Maturity53

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 60.4% 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 ~361 days

Total

2

Last Release

3808d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/79707?v=4)[Lars Strojny](/maintainers/lstrojny)[@lstrojny](https://github.com/lstrojny)

---

Top Contributors

[![alexanderdean](https://avatars.githubusercontent.com/u/200511?v=4)](https://github.com/alexanderdean "alexanderdean (284 commits)")[![fblundun](https://avatars.githubusercontent.com/u/5892914?v=4)](https://github.com/fblundun "fblundun (42 commits)")[![donspaulding](https://avatars.githubusercontent.com/u/7777?v=4)](https://github.com/donspaulding "donspaulding (28 commits)")[![lstrojny](https://avatars.githubusercontent.com/u/79707?v=4)](https://github.com/lstrojny "lstrojny (20 commits)")[![tsileo](https://avatars.githubusercontent.com/u/395031?v=4)](https://github.com/tsileo "tsileo (15 commits)")[![swijnands](https://avatars.githubusercontent.com/u/1218969?v=4)](https://github.com/swijnands "swijnands (11 commits)")[![mkatrenik](https://avatars.githubusercontent.com/u/887117?v=4)](https://github.com/mkatrenik "mkatrenik (11 commits)")[![BenFradet](https://avatars.githubusercontent.com/u/1737211?v=4)](https://github.com/BenFradet "BenFradet (10 commits)")[![AlexBenny](https://avatars.githubusercontent.com/u/7823329?v=4)](https://github.com/AlexBenny "AlexBenny (5 commits)")[![235](https://avatars.githubusercontent.com/u/649444?v=4)](https://github.com/235 "235 (5 commits)")[![jhirbour](https://avatars.githubusercontent.com/u/2355?v=4)](https://github.com/jhirbour "jhirbour (4 commits)")[![kingo55](https://avatars.githubusercontent.com/u/2361388?v=4)](https://github.com/kingo55 "kingo55 (3 commits)")[![emilssolmanis](https://avatars.githubusercontent.com/u/663720?v=4)](https://github.com/emilssolmanis "emilssolmanis (3 commits)")[![jethron](https://avatars.githubusercontent.com/u/1646397?v=4)](https://github.com/jethron "jethron (3 commits)")[![oguzhanunlu](https://avatars.githubusercontent.com/u/4786472?v=4)](https://github.com/oguzhanunlu "oguzhanunlu (3 commits)")[![Tombar](https://avatars.githubusercontent.com/u/141697?v=4)](https://github.com/Tombar "Tombar (3 commits)")[![EyePulp](https://avatars.githubusercontent.com/u/231081?v=4)](https://github.com/EyePulp "EyePulp (2 commits)")[![mleuthold](https://avatars.githubusercontent.com/u/24938292?v=4)](https://github.com/mleuthold "mleuthold (2 commits)")[![shuttie](https://avatars.githubusercontent.com/u/999061?v=4)](https://github.com/shuttie "shuttie (2 commits)")[![danm](https://avatars.githubusercontent.com/u/6394846?v=4)](https://github.com/danm "danm (2 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/snowplow-referer-parser/health.svg)

```
[![Health](https://phpackages.com/badges/snowplow-referer-parser/health.svg)](https://phpackages.com/packages/snowplow-referer-parser)
```

PHPackages © 2026

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