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

india-faker

v1.0.2

Published

Realistic Indian test data generator — names, addresses, UPI, Aadhaar-like IDs, bank details, students, orders, and more.

Readme

🇮🇳 india-faker

Realistic Indian test data generator for developers.

npm version License: MIT

Most fake data libraries generate Western-style data that doesn't match Indian formats — wrong names, wrong phone patterns, no UPI, no IFSC. india-faker fixes that.


🚀 Quick Start

npm install india-faker
import { person, student, order } from "india-faker";

console.log(person());
// { name: 'Aarav Sharma', gender: 'male', phone: '+91 9876543210', email: '[email protected]', region: 'north' }

console.log(student());
// { name: 'Priya Patil', rollNo: 'TYCS102', college: 'Pune University', percentage: 78.4, cgpa: 8.25, ... }

console.log(order());
// { orderId: 'ORD1234567890', product: 'Bluetooth Earbuds', price: 1499, payment: 'UPI', status: 'Delivered', ... }

✨ Features

  • Regional names — North, South, West, East Indian names with matching surnames
  • Indian phone numbers+91 9XXXXXXXXX format
  • Realistic addresses — 15 states, 150+ cities, correct PIN codes
  • UPI IDs — all major handles (@ybl, @okaxis, @paytm, etc.)
  • Aadhaar-like IDs — fake 12-digit format, intentionally NOT real
  • PAN-like IDs — fake 10-char format
  • IFSC codes — 15 major banks with correct prefixes
  • Student profiles — roll numbers, colleges, CGPA
  • E-commerce data — orders, products, Indian payment methods
  • Bulk generation — generate any number of records
  • Seed support — reproducible data for consistent tests

📖 API Reference

person(options?)

Generate an Indian person profile.

import { person } from "india-faker";

person();
// { name, gender, phone, email, region }

person({ gender: "female" });
person({ region: "south" });
person({ gender: "male", region: "west" });

Options: gender ("male" | "female"), region ("north" | "south" | "west" | "east")


phone()

import { phone } from "india-faker";
phone(); // "+91 8765432109"

email(name?)

import { email } from "india-faker";
email(); // "[email protected]"
email("Priya Patel"); // "[email protected]"

address(options?)

import { address } from "india-faker";

address();
// { addressLine: "Flat 302, Shree Residency", city: "Pune", state: "Maharashtra", pincode: "411038" }

address({ region: "south" });
address({ state: "Gujarat" });

Also exports: city(), stateName(), cityState(), pincode(state?)


aadhaar()

⚠️ Fake data only. Does NOT pass Verhoeff checksum. Cannot be used as a real Aadhaar number.

import { aadhaar } from "india-faker";
aadhaar(); // "4821 7643 9210"

pan()

⚠️ Fake data only. Not a real PAN number.

import { pan } from "india-faker";
pan(); // "ABCDE1234F"

upi(name?)

import { upi } from "india-faker";
upi(); // "rahul.verma@ybl"
upi("Neha Gupta"); // "neha.gupta@okaxis"

student(options?)

import { student } from "india-faker";

student();
// {
//   name: "Priya Patil",
//   gender: "female",
//   rollNo: "TYCS102",
//   course: "BE",
//   branch: "Computer Science",
//   college: "Pune University",
//   year: "Year 3",
//   percentage: 78.4,
//   cgpa: 8.25
// }

order()

import { order } from "india-faker";

order();
// {
//   orderId: "ORD1234567890",
//   product: "Bluetooth Earbuds",
//   quantity: 1,
//   price: 1499,
//   totalAmount: 1499,
//   payment: "UPI",
//   status: "Delivered"
// }

product()

import { product } from "india-faker";

product();
// {
//   sku: "SKU12345678",
//   name: "Smartwatch",
//   price: 3499,
//   mrp: 4999,
//   discount: "30%",
//   inStock: true,
//   rating: 4.2,
//   reviews: 1234
// }

bank()

import { bank } from "india-faker";

bank();
// {
//   bankName: "State Bank of India",
//   accountNumber: "XXXXXXX1234",
//   ifsc: "SBIN0012345",
//   accountType: "Savings",
//   branch: "Main Branch"
// }

Also exports: ifsc(bankName?)


generate(type, count, options?)

Bulk generate any type of record.

import { generate } from "india-faker";

generate("person", 100);
generate("student", 50, { region: "south" });
generate("order", 200);

Available types: person, phone, email, address, city, state, pincode, student, order, product, bank, ifsc, aadhaar, pan, upi


setSeed(number) / clearSeed()

Reproducible data for snapshot tests or demos.

import { setSeed, clearSeed, person } from "india-faker";

setSeed(123);
person(); // always returns the same result with seed 123
person(); // different, but reproducible

clearSeed(); // back to random

⚠️ Disclaimer

All data generated by this package is completely fake and intended for development and testing purposes only.

  • Aadhaar-like numbers do NOT pass real validation checks
  • PAN-like codes do NOT represent real taxpayers
  • No real person's data is used or generated
  • Do NOT use generated data for fraud, identity impersonation, or any illegal activity

🤝 Contributing

Pull requests welcome! Areas to contribute:

  • More regional data (Northeast India, Lakshadweep, etc.)
  • More colleges, banks, products
  • CLI tool support
  • TypeScript types
  • Regional language transliteration

📄 License

MIT © india-faker contributors