PHPackages                             boehm\_s/php-proximity-hash - 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. boehm\_s/php-proximity-hash

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

boehm\_s/php-proximity-hash
===========================

A PHP port of the proximityhash algorithm by Ashwin Nair

v0.1.2(5y ago)12.5kPHPPHP &gt;=7.2

Since Oct 6Pushed 5y ago1 watchersCompare

[ Source](https://github.com/boehm-s/php-proximity-hash)[ Packagist](https://packagist.org/packages/boehm_s/php-proximity-hash)[ RSS](/packages/boehm-s-php-proximity-hash/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (2)Versions (4)Used By (0)

php-proximity-hash [![Build Status](https://camo.githubusercontent.com/88149c70925af5b564d19d9a7a0304450e4d63c5c6d84ddc70eadea2be80c66f/68747470733a2f2f7472617669732d63692e636f6d2f626f65686d2d732f7068702d70726f78696d6974792d686173682e7376673f6272616e63683d6d61696e)](https://camo.githubusercontent.com/88149c70925af5b564d19d9a7a0304450e4d63c5c6d84ddc70eadea2be80c66f/68747470733a2f2f7472617669732d63692e636f6d2f626f65686d2d732f7068702d70726f78696d6974792d686173682e7376673f6272616e63683d6d61696e)
================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================

[](#php-proximity-hash-)

A port of [https://github.com/ashwin711/proximityhash](proximityhash) for PHP.

Geohash is a geocoding system invented by Gustavo Niemeyer and placed into the public domain. It is a hierarchical spatial data structure which subdivides space into buckets of grid shape, which is one of the many applications of what is known as a Z-order curve, and generally space-filling curves.

To visualize geohashes, you can go here :

ProximityHash generates a set of geohashes that cover a circular area, given the center coordinates and the radius.

Below is an illustration of what it looks like on a map :

[![ProximityHash illustration](./img/proximityhash-illustration.png)](./img/proximityhash-illustration.png)

Credits
=======

[](#credits)

```
https://github.com/ashwin711/proximityhash

```

Installation
============

[](#installation)

```
composer require boehm_s/php-proximity-hash

```

Usage
=====

[](#usage)

```
use boehm_s\ProximityHash;

$latitude  = 48.858156;
$longitude = 2.294776;
$radius    = 1000;     // in meters
$precision = 6;        // number of characters in the geohashes generated

$res = ProximityHash::generate($latitude, $longitude, $radius, $precision);
```

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

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

Total

3

Last Release

1869d ago

PHP version history (2 changes)v0.1.1PHP ^7.2

v0.1.2PHP &gt;=7.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/be203cd072d319ecb68d39845bbeac71cd1a762620ca027c84c07ab898c4ce2c?d=identicon)[boehm\_s](/maintainers/boehm_s)

---

Top Contributors

[![boehm-s](https://avatars.githubusercontent.com/u/15074274?v=4)](https://github.com/boehm-s "boehm-s (10 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/boehm-s-php-proximity-hash/health.svg)

```
[![Health](https://phpackages.com/badges/boehm-s-php-proximity-hash/health.svg)](https://phpackages.com/packages/boehm-s-php-proximity-hash)
```

PHPackages © 2026

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