PHPackages                             knightowl1031/php-precision-ceil - 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. knightowl1031/php-precision-ceil

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

knightowl1031/php-precision-ceil
================================

PHP helper for formatting numbers to a specific decimal precision.

V1.2(9mo ago)03MITPHP

Since Jul 23Pushed 9mo agoCompare

[ Source](https://github.com/knightowl1031/php-precision-ceil)[ Packagist](https://packagist.org/packages/knightowl1031/php-precision-ceil)[ RSS](/packages/knightowl1031-php-precision-ceil/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)DependenciesVersions (4)Used By (0)

KnightOwl1031/php-precision-ceil
================================

[](#knightowl1031php-precision-ceil)

A lightweight and pure PHP helper to accurately round numbers *up* to a specified decimal precision. This package addresses scenarios where PHP's native `ceil()` only rounds to the nearest whole integer, and `round()` doesn't offer a direct "always round up" mode to decimal places.

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

[](#installation)

You can install the package via Composer:

```
composer require knightowl1031/php-precision-ceil
```

Usage
-----

[](#usage)

The package provides a static method ceilPrecision within the Precision helper class.

PHP

```
