PHPackages                             nutandc/nepali-date-converter - 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. nutandc/nepali-date-converter

ActiveLibrary

nutandc/nepali-date-converter
=============================

Nepali Date Converter (BS &lt;-&gt; AD) for Nepal-first date conversion.

v1.1.3(4mo ago)02MITPHPPHP ^8.2CI passing

Since Jan 3Pushed 4mo agoCompare

[ Source](https://github.com/Nutandc/Nepali-BS-AD-Date-Converter)[ Packagist](https://packagist.org/packages/nutandc/nepali-date-converter)[ Docs](https://github.com/Nutandc/Nepali-BS-AD-Date-Converter)[ RSS](/packages/nutandc-nepali-date-converter/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (3)Versions (4)Used By (0)

Nepali BS-AD Date Converter
===========================

[](#nepali-bs-ad-date-converter)

[![CI](https://github.com/Nutandc/Nepali-BS-AD-Date-Converter/actions/workflows/ci.yml/badge.svg)](https://github.com/Nutandc/Nepali-BS-AD-Date-Converter/actions/workflows/ci.yml)[![Latest Version](https://camo.githubusercontent.com/624d006308ac94995c18611b731813e4cb852be1f59660762038dc9b9b5d93a7/68747470733a2f2f706f7365722e707567782e6f72672f6e7574616e64632f6e6570616c692d646174652d636f6e7665727465722f76657273696f6e)](https://packagist.org/packages/nutandc/nepali-date-converter)[![Total Downloads](https://camo.githubusercontent.com/60b3fa147d6eaf710429e99ea957902bfbbf5b27bfb06a3992f97f7e91c9d78c/68747470733a2f2f706f7365722e707567782e6f72672f6e7574616e64632f6e6570616c692d646174652d636f6e7665727465722f642f746f74616c)](https://packagist.org/packages/nutandc/nepali-date-converter)[![License](https://camo.githubusercontent.com/0cf660de1559d1aa162afed4bdf3f5047f77a26cbaf11178684514810e7327b7/68747470733a2f2f706f7365722e707567782e6f72672f6e7574616e64632f6e6570616c692d646174652d636f6e7665727465722f6c6963656e7365)](LICENSE)

A lightweight PHP package to convert Nepali Bikram Sambat (BS) dates to Gregorian (AD) and vice versa.

Requirements
------------

[](#requirements)

- PHP 8.2+
- Laravel 10+ (optional, for container binding)

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

[](#installation)

```
composer require nutandc/nepali-date-converter
```

Usage
-----

[](#usage)

```
use Nutandc\NepaliDateConverter\DateConverter;
use Nutandc\NepaliDateConverter\Enums\EnglishDateFormat;
use Nutandc\NepaliDateConverter\Enums\NepaliDateFormat;

$converter = new DateConverter();

// AD to BS
$bs = $converter->toNepali(2020, 10, 4);

$bs->toDateString();
// 2077-06-18

$bs->toFormattedEnglish();
// 18 Ashoj 2077, Sunday

$bs->toFormattedNepali();
// २०७७ असोज १८, आइतवार

$bs->toArray();
// ['year' => 2077, 'month' => 6, 'day' => 18, 'day_of_week' => 1]

$bs->toFormattedArray();
// ['year' => '२०७७', 'month' => 'असोज', 'day' => '१८', 'day_of_week' => 'आइतवार']

// AD to BS using DateTime/Carbon
$bs = $converter->toNepaliFromDateTime(new DateTimeImmutable('2022-09-08'));

// BS to AD
$ad = $converter->toEnglish(2077, 6, 18);

$ad->toDateString();
// 2020-10-04

$ad->toFormattedEnglish();
// October 4, 2020
```

Helpers
-------

[](#helpers)

```
$converter->daysInNepaliMonth(2077, 6); // 30
$converter->daysInEnglishMonth(2020, 2); // 29
```

Formatting
----------

[](#formatting)

```
$bs->format(NepaliDateFormat::DateString); // 2077-06-18
$bs->format(NepaliDateFormat::FormattedNepali); // २०७७ असोज १८, आइतवार

$ad->format(EnglishDateFormat::DateString); // 2020-10-04
$ad->format(EnglishDateFormat::FormattedEnglish); // October 4, 2020
```

Laravel 10+ Usage
-----------------

[](#laravel-10-usage)

```
use Nutandc\NepaliDateConverter\DateConverter;

$converter = app(DateConverter::class);
$bs = $converter->toNepali(2020, 10, 4);
```

Supported Range
---------------

[](#supported-range)

- AD: 1944 - 2033
- BS: 2000 - 2090

License
-------

[](#license)

MIT

###  Health Score

35

—

LowBetter than 79% of packages

Maintenance76

Regular maintenance activity

Popularity2

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity49

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

Total

3

Last Release

129d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f40665aea93e2d934f5efbec1457ddef646386850e51e7ee8891606cb4ef44b9?d=identicon)[Nutandc](/maintainers/Nutandc)

---

Top Contributors

[![Nutandc](https://avatars.githubusercontent.com/u/29918977?v=4)](https://github.com/Nutandc "Nutandc (14 commits)")

---

Tags

converterdateadnepalnepalibikram-sambatBS

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/nutandc-nepali-date-converter/health.svg)

```
[![Health](https://phpackages.com/badges/nutandc-nepali-date-converter/health.svg)](https://phpackages.com/packages/nutandc-nepali-date-converter)
```

###  Alternatives

[jaybizzle/laravel-migrations-organiser

A Laravel package to help organise migration files.

116399.4k2](/packages/jaybizzle-laravel-migrations-organiser)[sbsaga/toon

🧠 TOON for Laravel — a compact, human-readable, and token-efficient data format for AI prompts &amp; LLM contexts. Perfect for ChatGPT, Gemini, Claude, Mistral, and OpenAI integrations (JSON ⇄ TOON).

6115.6k](/packages/sbsaga-toon)[laravel-shift/curl-converter

A command line tool to convert curl requests to Laravel HTTP requests.

935.3k](/packages/laravel-shift-curl-converter)[mohamedsabil83/laravel-hijrian

Hijri-Gregorian date converter for Laravel

1220.0k](/packages/mohamedsabil83-laravel-hijrian)[zman/zman

A Jewish date converter and helper.

186.4k](/packages/zman-zman)

PHPackages © 2026

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