PHPackages                             redmatter/chrono - 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. redmatter/chrono

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

redmatter/chrono
================

Accurate, testable and consistent API for clocks and times

v1.0.0(5y ago)14MITPHPPHP &gt;=5.4.0

Since Aug 14Pushed 5y agoCompare

[ Source](https://github.com/redmatter/php-chrono)[ Packagist](https://packagist.org/packages/redmatter/chrono)[ RSS](/packages/redmatter-chrono/feed)WikiDiscussions master Synced 6d ago

READMEChangelogDependencies (5)Versions (6)Used By (0)

PHP Chrono
==========

[](#php-chrono)

[![Build Status](https://camo.githubusercontent.com/94a33b58751c4ce9a5395e99730849716f6c38c36dcb0317321d11967322d8d5/68747470733a2f2f7472617669732d63692e636f6d2f636f64656d656469632d6f73732f7068702d6368726f6e6f2e7376673f6272616e63683d6d6173746572)](https://travis-ci.com/codemedic-oss/php-chrono)

Clock and time utilities with focus on accuracy and testability.

The design is influenced by [`chrono`](https://en.cppreference.com/w/cpp/chrono) library in C++ and [`time.Duration`](https://golang.org/pkg/time/) library in golang.

The one reason, if you need convincing, to use this library would be to enhance the testability of your code that relies on system-time. See [examples](examples).

### API Reference

[](#api-reference)

Documentation can be [found here](docs/phpdoc.md).

How to contribute?
==================

[](#how-to-contribute)

Please feel free to fork and submit a pull request. Bug fixes, improvements, unit-tests and usability comments are most welcome.

If you are to contribute code, please do log an issue before starting to work on the code. Your changes should come with working unit tests; all tests must pass.

Coding standard followed here is `PSR-2`.

License
-------

[](#license)

This library is licensed under [MIT license](LICENSE).

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity53

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

Total

4

Last Release

2084d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/482e4d123ddfbe5ed61fd256f7ed0eeb2ac086175469960d1e04637e0f59f85f?d=identicon)[redmatter](/maintainers/redmatter)

---

Top Contributors

[![codemedic](https://avatars.githubusercontent.com/u/691011?v=4)](https://github.com/codemedic "codemedic (27 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/redmatter-chrono/health.svg)

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

###  Alternatives

[composer/composer

Composer helps you declare, manage and install dependencies of PHP projects. It ensures you have the right stack everywhere.

29.4k187.2M2.6k](/packages/composer-composer)[kohkimakimoto/background-process

A minimum library to run background processes asynchronously.

351.4k](/packages/kohkimakimoto-background-process)

PHPackages © 2026

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