npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

naija-tax-utils

v1.0.0

Published

Nigerian tax calculation utilities — VAT, PAYE, WHT, CIT, Pension, NHF. TypeScript-first, zero dependencies.

Readme

naija-tax-utils

Nigerian tax calculation utilities for developers. TypeScript-first. Zero dependencies.

npm version License: MIT

Handles the Nigerian tax calculations developers actually need — VAT, PAYE, Withholding Tax, Company Income Tax, Pension (PenCom), and NHF — all based on current FIRS guidelines and Finance Acts.


Install

npm install naija-tax-utils
# or
yarn add naija-tax-utils

Usage

VAT (Value Added Tax — 7.5%)

import { calculateVAT, extractVAT, isVATRegistrationRequired } from "naija-tax-utils";

// Add VAT to an amount
calculateVAT(10_000);
// { gross: 10750, taxAmount: 750, net: 10000, effectiveRate: 7.5 }

// Extract VAT from a VAT-inclusive amount
extractVAT(10_750);
// { gross: 10750, taxAmount: 750, net: 10000, effectiveRate: 7.5 }

// Check if VAT registration is required (threshold: ₦25m turnover)
isVATRegistrationRequired(30_000_000); // true
isVATRegistrationRequired(10_000_000); // false

PAYE (Personal Income Tax)

import { calculatePAYE, calculateMonthlyPAYE } from "naija-tax-utils";

// Annual gross income
const result = calculatePAYE(3_600_000);
console.log(result.taxAmount);       // Annual PAYE
console.log(result.monthlyTax);      // Monthly deduction
console.log(result.effectiveRate);   // e.g. 14.2%
console.log(result.breakdown);       // Per-band breakdown

// From monthly salary
const monthly = calculateMonthlyPAYE(300_000);

WHT (Withholding Tax)

import { calculateWHT, getWHTRates } from "naija-tax-utils";

calculateWHT(500_000, "consultancy");
// { gross: 500000, taxAmount: 50000, net: 450000, effectiveRate: 10 }

calculateWHT(2_000_000, "construction");
// { gross: 2000000, taxAmount: 50000, net: 1950000, effectiveRate: 2.5 }

// Available types: dividends | interest | rent | royalties | commission |
//                  consultancy | construction | contracts | directorFees | supplyOfGoods
getWHTRates(); // returns all rates with descriptions

CIT (Company Income Tax)

import { calculateCIT, getCITRate } from "naija-tax-utils";

// Large company (turnover > ₦100m) — 30%
calculateCIT(150_000_000, 30_000_000);
// { companySize: 'large', taxAmount: 9000000, effectiveRate: 30, isExempt: false }

// Small company (turnover < ₦25m) — exempt
calculateCIT(10_000_000, 2_000_000);
// { companySize: 'small', taxAmount: 0, effectiveRate: 0, isExempt: true }

Pension (PenCom Contributory Pension Scheme)

import { calculatePension } from "naija-tax-utils";

// Employee: 8% | Employer: 10% of (basic + housing + transport)
calculatePension(150_000, 50_000, 30_000);
// {
//   grossEmolument: 230000,
//   employeeContribution: 18400,
//   employerContribution: 23000,
//   totalContribution: 41400
// }

NHF (National Housing Fund)

import { calculateNHF } from "naija-tax-utils";

calculateNHF(100_000);
// { basicSalary: 100000, contribution: 2500, isRequired: true, annualContribution: 30000 }

Tax Reference

| Tax | Rate | Basis | |-----|------|-------| | VAT | 7.5% | Transaction value | | PAYE | 7% – 24% | Graduated bands on taxable income | | WHT (Consultancy) | 10% | Contract value | | WHT (Construction) | 2.5% | Contract value | | CIT (Large) | 30% | Taxable profit | | CIT (Medium) | 20% | Taxable profit | | CIT (Small) | 0% | Exempt | | Pension (Employee) | 8% | Monthly emolument | | Pension (Employer) | 10% | Monthly emolument | | NHF | 2.5% | Basic salary |

Rates are based on FIRS guidelines and Finance Acts up to 2023. Always verify with your tax professional for compliance.


Contributing

PRs welcome. If a rate has changed or a new Finance Act affects any computation, please open an issue with a reference to the official FIRS/FMFBNP source.


License

MIT © Marcus Aregbe