PHPackages                             salem/tracker - 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. salem/tracker

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

salem/tracker
=============

Track your project by getting visitors data.

v1.0.2(6y ago)1211MITPHPPHP &gt;=7.1.3

Since Apr 5Pushed 6y ago1 watchersCompare

[ Source](https://github.com/ma7moudsalem1/tracker)[ Packagist](https://packagist.org/packages/salem/tracker)[ RSS](/packages/salem-tracker/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependenciesVersions (3)Used By (0)

Laravel Visitors Tracker
========================

[](#laravel-visitors-tracker)

[![GitHub forks](https://camo.githubusercontent.com/ca79c7fa70b8fd3378d563ddf4d457f9bbeeebab53be5d6509c78b3b28afc4b8/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f666f726b732f6d61376d6f756473616c656d312f747261636b6572)](https://github.com/ma7moudsalem1/tracker/network) [![GitHub stars](https://camo.githubusercontent.com/a238e2e0c65f9e579201e7de569fbb6b3d6550f83534791b06995c0f1b950c3d/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f73746172732f6d61376d6f756473616c656d312f747261636b6572)](https://github.com/ma7moudsalem1/tracker/stargazers)

About
-----

[](#about)

`Salem\Tracker` is a Laravel package makes it easy to track your Laravel project by gathering a lot of information from your visitor request and **IP Address**.

Features
--------

[](#features)

- You can get this data about your visitor without each day like:

    - **The Country**.
    - **The City**.
    - **The currency of the visitor country**.
    - **Latitude and Longitude**.
    - **Browser and the version of this browser**.
    - **Platform**.
- After collecting the data from your visitors you can show them through an API in the package.

    - (GET) `/tracker/all` To get all the tracker records from your database.
    - (GET) `/tracker/show/{id}` To get the tracker data by ID form your database.
    - (GET) `/tracker/ip/{ip}` To get the IP data from your database.
- The package also make it easy for you to get the data that you want like:

    - **Check if this IP Tracked before**
    - **Last visit of this IP**
    - **Most visitors from ` Country`,`City`,`Browser`,`Platform`**

Installation
------------

[](#installation)

```
composer require salem/tracker

```

Run the migration, You have two ways to do it:

- Run `php artisan migrate` directly.
- Publish the migration `php artisan vendor:publish -- *provider="Salem\Tracker\TrackerServiceProvider" --tag=migration` Then `php artisan migrate`.

Publish the config file (optional)

- Run `php artisan vendor:publish --provider="Salem\Tracker\TrackerServiceProvider" --   tag=config`.
- You can publish all files by run `php artisan vendor:publish --provider="Salem\Tracker\TrackerServiceProvider"`

Put `Provicer` &amp; `Aliases` in `app.php` (optional)

```
Salem\Tracker\TrackerServiceProvider::class,

```

```
'Tracker' => Salem\Tracker\Facades\Tracker::class,

```

How To Use It.
--------------

[](#how-to-use-it)

The package provide many ways to use :

- You Can put the package middleware `\Salem\Tracker\Controls\Http\middleware\VisitorTrack::class,` in `App\Http\Kernel` inside `$middleware` array.
- Or You can put this script in your view before `` to send Ajax request to save visitor's data `{!! Tracker::script() !!}` or `{!! getTrack()->script() !!}`.

Also the package provide many fuctions to get your data:

- `Tracker::trackedBefore($ip)` To check if the given IP tracked before and its data exists in the database or not.
- `Tracker::getBest($compare, $number)` To give you the top `$number` of given `compare`, Compare could be `ip_address`, `country_name`, `city`, `currency`, `country_code`, `browser`, `browser_version`, `platform` and for example if you put the number with 10 it gives you top 10 of the given compare.
- `Tracker::getPaginatedTracking($paginate = 20, $full = false)` To get paginated records from your database, `$full` boolean that make sure if you want full data or formated data.
- `Tracker::getTrackingPaginatedByIp($ip, $paginate = 20, $full = false)` To get paginated records from your database of the given IP, `$full` boolean that make sure if you want full data or formated data.
- `Tracker::getTracking($id, $full = false)` To get the tracking record from your database by ID with formated or not formated way.
- `Tracker::getTrackingByIp($ip, $full = false)` To get the tracking record from your database by IP with formated or not formated way.
- `Tracker::getLastIpVisit($ip, $full = false)` To get formated or not formated data of last visit of the given IP.

All functions are avalible with package helper `getTrack()` for example `getTrack()->getTrackingByIp($ip, $full = false)`.

Credits
-------

[](#credits)

.

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 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 ~0 days

Total

2

Last Release

2233d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/496de8204f6206e6fccda68ae1cf6f78c6eb5112368c6ef3795e44d2337bc794?d=identicon)[ma7moudsalem1](/maintainers/ma7moudsalem1)

---

Top Contributors

[![ma7salem](https://avatars.githubusercontent.com/u/25405952?v=4)](https://github.com/ma7salem "ma7salem (2 commits)")

---

Tags

laraveltrackinguser agentvisitorlocationtracker

### Embed Badge

![Health badge](/badges/salem-tracker/health.svg)

```
[![Health](https://phpackages.com/badges/salem-tracker/health.svg)](https://phpackages.com/packages/salem-tracker)
```

###  Alternatives

[pragmarx/tracker

A Laravel Visitor Tracker

2.9k300.0k1](/packages/pragmarx-tracker)

PHPackages © 2026

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