numpy-financial
Simple financial functions
What it is and what it does
numpy-financial is a standalone library of financial functions extracted from NumPy before they were deprecated and removed. It provides functions for calculating internal rate of return (IRR), net present value (NPV), payment amounts, interest rates, and other elementary financial metrics commonly used in investment analysis and accounting. The package is a direct replacement for code that previously relied on NumPy's built-in financial module.
The library depends only on numpy and installs as a pure Python wheel with low friction. It targets financial professionals and developers building accounting or investment analysis tools. However, the package has not been actively maintained since its initial release in 2019, and the last commit was 2025-05-20, making its long-term compatibility with modern Python and numpy versions unclear.
Use it for:
- Calculate internal rate of return (IRR) for investment portfolios or cash flow sequences.
- Compute net present value (NPV) to evaluate project profitability at a given discount rate.
- Determine periodic payment amounts for loans or annuities using PMT calculations.
- Analyze cash flow timing and financial metrics in accounting or investment applications.
- Migrate legacy code that relied on NumPy's deprecated financial functions.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides elementary financial functions (IRR, NPV, PMT, and others) that were deprecated and removed from NumPy, offering a dedicated replacement for financial calculations.
Yes, with conditions. The package is stable, permissively licensed, and has low install friction. It is appropriate for financial calculations in production systems that do not require active maintenance. However, given the aging status (no releases since 2019) and unclear compatibility with modern Python and recent numpy versions, verify that it works with your target environment before committing to it. For new projects, consider whether a more actively maintained financial library better suits your long-term needs.
Install
numpy-financial on PyPI
pip
pip install numpy-financialuv
uv add numpy-financialpoetry
poetry add numpy-financialInstalling numpy-financial
Before you install
Low friction: pure Python wheel with only numpy as a runtime dependency. Maintenance is aging—last release was 2019-10-18 and the repository shows no recent activity despite being archived=false, though it remains stable and Production/Stable classified.
License in practice
BSD 3-Clause permissive license allows commercial and private use with minimal restrictions; suitable for most projects that can include a license notice.
Quickstart
pip install numpy-financial
import numpy_financial as npf
irr_result = npf.irr([-250000, 100000, 150000, 200000, 250000, 300000])
Requires Python >= 3.5 and numpy as a runtime dependency.
Verify before relying
- Whether the package receives security patches or maintenance despite the aging status and 2019 release date.
- Current compatibility with modern numpy versions and recent Python versions, given the last release predates them.
Package facts
| License | BSD 3-Clause (permissive) |
| Python support | supports the current Python release (>=3.5) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — numpy |
| Maintenance | aging — 2,492 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 5,860,608/month — #2,022 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: numpy_financial-1.0.0-py3-none-any.whl
Tags
More Software Development packages
Provides backported and experimental type hints…
permissive · top 100 on PyPI
numpyNumPy provides an N-dimensional array object…
permissive · top 100 on PyPI
fastapiFastAPI is a Python web framework for building…
permissive · top 100 on PyPI
annotated-docProvides a way to document function parameters,…
permissive · top 100 on PyPI
typerTyper builds command-line applications from…
permissive · top 1,000 on PyPI
distlibDistlib provides low-level packaging utilities…
permissive · top 1,000 on PyPI
pyxirrPyXIRR is a Rust-backed library that computes…
permissive · top 5,000 on PyPI
pyportfoliooptPyPortfolioOpt implements portfolio…
permissive · top 15,000 on PyPI
rets-pythonPython 3 client library for querying and…
permissive · top 15,000 on PyPI
riskfolio-libRiskfolio-Lib builds optimized investment…
permissive · top 15,000 on PyPI
pandas-taProvides over 150 technical analysis indicators…
unclear · top 5,000 on PyPI
quantstatsQuantStats computes portfolio performance…
permissive · top 15,000 on PyPI
skfolioskfolio is a Python library for portfolio…
permissive · top 15,000 on PyPI
vollibvollib calculates option prices, implied…
permissive · top 15,000 on PyPI
py-moneyedProvides Money and Currency classes for…
permissive · top 5,000 on PyPI
yfinanceFetches financial and market data from Yahoo…
permissive · top 1,000 on PyPI