PHPackages                             hareku/laravel-follow - 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. hareku/laravel-follow

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

hareku/laravel-follow
=====================

Laravel 5 user follow system

3.0.0(8y ago)33892[2 issues](https://github.com/hareku/laravel-follow/issues)MITPHPPHP &gt;=7.0

Since Feb 5Pushed 8y ago2 watchersCompare

[ Source](https://github.com/hareku/laravel-follow)[ Packagist](https://packagist.org/packages/hareku/laravel-follow)[ RSS](/packages/hareku-laravel-follow/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (10)Dependencies (4)Versions (13)Used By (0)

Laravel 5 Follow System
=======================

[](#laravel-5-follow-system)

This package helps you to add user follow system to your project.

- So simply and easy.
- Use "ON DELETE CASCADE" in follow relationships table.

Require
-------

[](#require)

- *Support Laravel 5.4~*
- *Required php &gt;=7.0* (v1.\* &gt;=5.6.4)

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

[](#installation)

First, pull in the package through Composer.

Run `composer require hareku/laravel-follow`

And then, include the service provider within `config/app.php`.

```
'providers' => [
    Hareku\LaravelFollow\FollowServiceProvider::class,
];
```

Publish the config file. (follow.php)

```
$ php artisan vendor:publish --provider="Hareku\LaravelFollow\FollowServiceProvider"
```

Finally, use Followable trait in User model.

```
use Hareku\LaravelFollow\Traits\Followable;

class User extends Model
{
    use Followable;
}
```

Usage
-----

[](#usage)

### Follow a user or users

[](#follow-a-user-or-users)

```
$user->follow(1);
$user->follow([1,2,3,4]);
```

### Add followers

[](#add-followers)

```
$user->addFollowers(1);
$user->addFollowers([1,2,3,4]);
```

### Unfollow a user or users

[](#unfollow-a-user-or-users)

```
$user->unfollow(1);
$user->unfollow([1,2,3,4]);
```

### Get followers / followees

[](#get-followers--followees)

```
// followers
$user->followers()->get(); // Get follower user models.
$user->followerRelationships()->get(); // Get follower relationship models.

// followees
$user->followees()->get();
$user->followeeRelationships()->get();
```

### Check if follow

[](#check-if-follow)

```
$user->isFollowing(1);
$user->isFollowing([1,2,3,4]);
```

### Check if followed by

[](#check-if-followed-by)

```
$user->isFollowedBy(1);
$user->isFollowedBy([1,2,3,4]);
```

### Check if mutual follow

[](#check-if-mutual-follow)

```
$user->isMutualFollow(1);
$user->isMutualFollow([1,2,3,4]);
```

### Get follower/followee IDs

[](#get-followerfollowee-ids)

```
$user->follow([1,2,3]);
$user->followerIds(); // [1,2,3]

$user->followeeIds();
```

### Reject user ids

[](#reject-user-ids)

```
$user->follow([1,2,3]);
$user->rejectNotFollowee([1,2,3,4,5]); // [1,2,3]
```

```
$user->followers()->pluck('id')->all(); // [1,2,3]
$user->rejectNotFollower([1,2,3,4,5]); // [1,2,3]
```

License
-------

[](#license)

MIT

Author
------

[](#author)

hareku ()

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance7

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity65

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

Recently: every ~0 days

Total

11

Last Release

3269d ago

Major Versions

1.1.1 → 2.0.02017-05-29

2.2.0 → 3.0.02017-05-30

PHP version history (2 changes)1.0.0PHP &gt;=5.6.4

2.0.0PHP &gt;=7.0

### Community

Maintainers

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

---

Top Contributors

[![hareku](https://avatars.githubusercontent.com/u/17667652?v=4)](https://github.com/hareku "hareku (37 commits)")

---

Tags

laravelFollow

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/hareku-laravel-follow/health.svg)

```
[![Health](https://phpackages.com/badges/hareku-laravel-follow/health.svg)](https://phpackages.com/packages/hareku-laravel-follow)
```

###  Alternatives

[barryvdh/laravel-ide-helper

Laravel IDE Helper, generates correct PHPDocs for all Facade classes, to improve auto-completion.

14.9k123.0M687](/packages/barryvdh-laravel-ide-helper)[laracraft-tech/laravel-useful-additions

A collection of useful Laravel additions!

58109.4k](/packages/laracraft-tech-laravel-useful-additions)[glhd/special

1929.4k](/packages/glhd-special)[bjuppa/laravel-blog

Add blog functionality to your Laravel project

483.3k2](/packages/bjuppa-laravel-blog)

PHPackages © 2026

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