PHPackages                             baspa/laravel-timezones - 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. baspa/laravel-timezones

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

baspa/laravel-timezones
=======================

Laravel package to generate arrays of available timezones to be used in lists.

v1.4.0(1mo ago)218.1k↑106.3%[1 PRs](https://github.com/Baspa/laravel-timezones/pulls)2MITPHPPHP ^8.2|^8.3|^8.4CI passing

Since Jan 31Pushed 4mo ago1 watchersCompare

[ Source](https://github.com/Baspa/laravel-timezones)[ Packagist](https://packagist.org/packages/baspa/laravel-timezones)[ Docs](https://github.com/baspa/laravel-timezones)[ GitHub Sponsors](https://github.com/baspa)[ RSS](/packages/baspa-laravel-timezones/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (4)Dependencies (27)Versions (18)Used By (2)

[![Banner](/docs/banner.png)](/docs/banner.png)

Laravel package to generate arrays of available timezones to be used in lists.
==============================================================================

[](#laravel-package-to-generate-arrays-of-available-timezones-to-be-used-in-lists)

[![Latest Version on Packagist](https://camo.githubusercontent.com/37f9cdfd2803dd24fcb378deff5853049df66a7f9a097c2a6875f3699fa94cfb/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f62617370612f6c61726176656c2d74696d657a6f6e65732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/baspa/laravel-timezones)[![GitHub Tests Action Status](https://camo.githubusercontent.com/f0bf5465f62b526d2c8a821cd7e91012338472ce642ef165a65228762f48a8ee/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f62617370612f6c61726176656c2d74696d657a6f6e65732f72756e2d74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/baspa/laravel-timezones/actions?query=workflow%3Arun-tests+branch%3Amain)[![GitHub Code Style Action Status](https://camo.githubusercontent.com/dc973f85ca626e8fc300b3ba4d0254ed194b2b5e3d45c1616cdb574ef1fc2952/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f62617370612f6c61726176656c2d74696d657a6f6e65732f6669782d7068702d636f64652d7374796c652d6973737565732e796d6c3f6272616e63683d6d61696e266c6162656c3d636f64652532307374796c65267374796c653d666c61742d737175617265)](https://github.com/baspa/laravel-timezones/actions?query=workflow%3A%22Fix+PHP+code+style+issues%22+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/ea96af51ae9d7f85c3b8d39b349fd0d4cf8c4587f1771427b66ded45026e75c9/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f62617370612f6c61726176656c2d74696d657a6f6e65732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/baspa/laravel-timezones)

The Laravel Timezones package is a convenient solution for Laravel developers who need to include a dropdown menu of timezones in their applications. This package simplifies the process of incorporating a timezone selection feature, saving developers valuable time and effort.

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

[](#installation)

You can install the package via composer:

```
composer require baspa/laravel-timezones
```

Usage
-----

[](#usage)

### Timezones grouped by continent

[](#timezones-grouped-by-continent)

```
use Baspa\Timezones\Facades\Timezones;
//
$groupedTimezones = Timezones::toArray(grouped: true);
```

### All timezones

[](#all-timezones)

```
use Baspa\Timezones\Facades\Timezones;
//
$timezones = Timezones::toArray();
```

### Exclude continents

[](#exclude-continents)

```
use Baspa\Timezones\Facades\Timezones;
//
$timezones = Timezones::excludeContinents(['Africa', 'America'])
    ->toArray();
```

### Show offset

[](#show-offset)

```
$timezones = Timezones::showOffset()->toArray();
// or
$timezones = Timezones::showOffset(showOffset: false)->toArray();
```

### Include general timezones

[](#include-general-timezones)

To include general timezones like GMT or UTC use the `includeGeneral` method.

```
$timezones = Timezones::includeGeneral()->toArray();
```

### Show country names

[](#show-country-names)

To include country names alongside timezone labels use the `showCountry` method. This uses PHP's built-in timezone data combined with the [league/iso3166](https://github.com/thephpleague/iso3166) package to provide accurate country names.

```
// Basic usage with country names
$timezones = Timezones::showCountry()->toArray();
// Output: "Amsterdam (Netherlands)"

// Combined with other methods
$timezones = Timezones::showCountry()
    ->showOffset(false)
    ->toArray();
// Output: "Amsterdam (Netherlands)"

// With full continent names preserved
$timezones = Timezones::showCountry()->toArrayWithContinents();
// Output: "Europe / Amsterdam (Netherlands)"

// Grouped by continent with country names
$timezones = Timezones::showCountry()->toArray(grouped: true);
```

Testing
-------

[](#testing)

```
composer test
```

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

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

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Credits
-------

[](#credits)

- [Baspa](https://github.com/Baspa)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

52

—

FairBetter than 96% of packages

Maintenance82

Actively maintained with recent releases

Popularity29

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity68

Established project with proven stability

 Bus Factor1

Top contributor holds 58.3% 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 ~55 days

Recently: every ~97 days

Total

15

Last Release

56d ago

PHP version history (3 changes)v1.0.0PHP ^8.1

v1.2.0PHP ^8.1|^8.2

v1.4.0PHP ^8.2|^8.3|^8.4

### Community

Maintainers

![](https://www.gravatar.com/avatar/1b4c1c73be31056bf9c8f132938f77de518259ed02f5675e4339bc7dfab5b13c?d=identicon)[Baspa](/maintainers/Baspa)

---

Top Contributors

[![Baspa](https://avatars.githubusercontent.com/u/10845460?v=4)](https://github.com/Baspa "Baspa (35 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (16 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (8 commits)")[![markvaneijk](https://avatars.githubusercontent.com/u/1925388?v=4)](https://github.com/markvaneijk "markvaneijk (1 commits)")

---

Tags

laraveltimezoneslaravellaravel-timezonesBaspa

###  Code Quality

TestsPest

Static AnalysisPHPStan

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/baspa-laravel-timezones/health.svg)

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

###  Alternatives

[spatie/laravel-data

Create unified resources and data transfer objects

1.8k28.9M627](/packages/spatie-laravel-data)[spatie/laravel-livewire-wizard

Build wizards using Livewire

4061.0M4](/packages/spatie-laravel-livewire-wizard)[hirethunk/verbs

An event sourcing package that feels nice.

513162.9k6](/packages/hirethunk-verbs)[worksome/exchange

Check Exchange Rates for any currency in Laravel.

123544.7k](/packages/worksome-exchange)[ralphjsmit/livewire-urls

Get the previous and current url in Livewire.

82270.3k4](/packages/ralphjsmit-livewire-urls)[hydrat/filament-table-layout-toggle

Filament plugin adding a toggle button to tables, allowing user to switch between Grid and Table layouts.

6292.3k1](/packages/hydrat-filament-table-layout-toggle)

PHPackages © 2026

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