Skip to content

Nepali Number to Words in JavaScript (np-NP)

Use np-NP when your application needs Nepali number words with Indian number scale (lakh, crore) and Nepali Rupee currency.

Locale codes: np-NP · Numbering system: Indian · Currency: रुपैयाँ (Rupee) / पैसा (Paisa) · Script: Devanagari

Install

bash
npm install to-words

Basic Conversion

js
import { ToWords } from 'to-words';

const tw = new ToWords({ localeCode: 'np-NP' });

tw.convert(100);
tw.convert(100000); // one lakh
tw.convert(10000000); // one crore

Currency - Rupee / Paisa

js
tw.convert(1234.56, { currency: true });
tw.convert('500.00', { currency: true, includeZeroFractional: true });

Ordinal Numbers

js
tw.toOrdinal(1);
tw.toOrdinal(10);

Tree-shakeable (single-locale) import

js
import { toWords, toCurrency, toOrdinal } from 'to-words/np-NP';

toWords(100000);
toCurrency(999.99);

Locale Codes

Locale codeCountryCurrencyNotes
np-NPNepalरुपैयाँ / पैसाIndian scale; Devanagari script

FAQ

Q: Which locale code should I use for Nepali number-to-words output? Use np-NP.

Q: Does np-NP use the Indian number scale (lakh, crore)? Yes. np-NP uses Indian grouping with lakh and crore as the scale units.

Released under the MIT License.