PHPackages                             cevin/geohash - 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. cevin/geohash

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

cevin/geohash
=============

Geohash library for php

1.0(9y ago)192.0k↓100%3[1 issues](https://github.com/cevin/geohash/issues)MITPHPPHP &gt;=5.3.0

Since Nov 21Pushed 6y ago1 watchersCompare

[ Source](https://github.com/cevin/geohash)[ Packagist](https://packagist.org/packages/cevin/geohash)[ Docs](https://github.com/cevin/geohash)[ RSS](/packages/cevin-geohash/feed)WikiDiscussions master Synced today

READMEChangelog (1)DependenciesVersions (2)Used By (0)

geohash
=======

[](#geohash)

What's GeoHash
--------------

[](#whats-geohash)

LINK:

Usage
-----

[](#usage)

```
use Cevin\Geohash;

$length = 6;

$geohash = new Geohash();

$hash = substr($geohash->encode('latitude','longitude'), 0, $length);

$box = $geohash->neighbors($hash);

$box[] = $hash;

$in_str = "'".implode("','", $box)."'";

// PHP
// $sql = "SELECT FROM `table` WHERE LEFT(geohash, {$length}) IN ($in_str)";
// echo $sql;

// OUTPUT
// SELECT FROM `table` WHERE LEFT(geohash, 6) IN ('xxxxxx','aaaaaa', ......)
```

License
-------

[](#license)

[Anti-996 License](https://github.com/996icu/996.ICU/blob/master/LICENSE)

###  Health Score

32

—

LowBetter than 74% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity28

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity58

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

Unknown

Total

1

Last Release

3409d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/2aded16aa0933ff5531b3f5898075e440488475261be8995009121960f0751ed?d=identicon)[cevin](/maintainers/cevin)

---

Top Contributors

[![cevin](https://avatars.githubusercontent.com/u/338110?v=4)](https://github.com/cevin "cevin (16 commits)")

---

Tags

geohash

### Embed Badge

![Health badge](/badges/cevin-geohash/health.svg)

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

###  Alternatives

[knplabs/knp-time-bundle

Making your dates and durations look sensible and descriptive

6218.7M34](/packages/knplabs-knp-time-bundle)[phpseclib/bcmath_compat

PHP 5.x-8.x polyfill for bcmath extension

16620.4M11](/packages/phpseclib-bcmath-compat)[lvht/geohash

geohash like python-geohash

77572.9k](/packages/lvht-geohash)[saikiran/geohash

Geohash Algorithm to encode geographic coordinates to a string of letters and digits

43435.7k1](/packages/saikiran-geohash)[laravie/serialize-queries

Serializable Laravel Query Builder

696.9M4](/packages/laravie-serialize-queries)[roots/wp-config

Collect configuration values and safely define() them

527.4M69](/packages/roots-wp-config)

PHPackages © 2026

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