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

stripe-fee-estimator

v1.1.0

Published

Estimate Stripe processing fees, reverse-calculate gross charges, and use custom fee presets from the CLI or as a JavaScript library.

Readme

stripe-fee-estimator

Estimate Stripe-style processing fees from the command line or from JavaScript.

This package supports normal gross-to-net estimates, reverse calculations for target net payouts, built-in fee variations, custom one-time fees, and saved custom presets.

Disclaimer: This tool provides estimates only. Actual Stripe pricing can vary by country, payment method, custom pricing, taxes, disputes, Connect, payout method, and other Stripe products. Always verify against your Stripe Dashboard and Stripe's official pricing page.

Install

npm install -g stripe-fee-estimator

Or run without installing:

npx stripe-fee-estimator 100

CLI usage

stripe-fee-estimator 100

Example output:

Gross:      $100.00
Fee:        $3.20
You get:    $96.80

Profile:    Online domestic card
Rate:       2.9% + $0.30

Reverse-calculate the amount to charge:

stripe-fee-estimator --net 100
Target net: $100.00
Charge:     $103.30
Fee:        $3.30
You get:    $100.00

Built-in fee profiles

stripe-fee-estimator 100 --online
stripe-fee-estimator 100 --in-person
stripe-fee-estimator 100 --ach

Built-in variations

stripe-fee-estimator 100 --manual
stripe-fee-estimator 100 --international
stripe-fee-estimator 100 --currency-conversion
stripe-fee-estimator 100 --dispute-protection
stripe-fee-estimator 100 --instant-payout

You can combine them:

stripe-fee-estimator 100 --online --international --currency-conversion

Custom one-time fees

Add a one-time fixed amount:

stripe-fee-estimator 100 --one-time-fixed 2.00

Add a one-time percentage:

stripe-fee-estimator 100 --one-time-percent 1.5%

Add custom recurring-style fee components:

stripe-fee-estimator 100 --add-percent 1.5% --add-fixed 0.10

Override the base fee entirely:

stripe-fee-estimator 100 --percent 2.9% --fixed 0.30

Saved custom presets

Save a preset:

stripe-fee-estimator --save-preset schoolclub --percent 2.5% --fixed 0.25 --label "School club processor"

Use it later:

stripe-fee-estimator 100 --preset schoolclub

List presets:

stripe-fee-estimator --list-presets

Saved presets are stored locally at:

~/.stripe-fee-estimator/presets.json

JSON output

stripe-fee-estimator 100 --json

JavaScript usage

import { estimateStripeFee, grossFromNet } from "stripe-fee-estimator";

const estimate = estimateStripeFee(100, {
  preset: "online",
  addons: ["international", "currencyConversion"]
});

console.log(estimate.net);

const charge = grossFromNet(100, {
  preset: "online"
});

console.log(charge.gross);

API

estimateStripeFee(amount, options)

Calculates fee and net amount from a gross charge.

grossFromNet(targetNet, options)

Calculates the approximate gross charge needed to receive a target net amount.

Options

{
  preset: "online",
  addons: ["international"],
  customPercent: 0.015,
  customFixed: 0.10,
  oneTimePercent: 0.01,
  oneTimeFixed: 2.00,
  overridePercent: 0.029,
  overrideFixed: 0.30,
  currency: "USD"
}

Publish checklist

Before publishing:

npm test
npm pack --dry-run
npm login
npm publish --access public

For updates:

npm version patch
npm publish

Repository

GitHub repository:

https://github.com/ethantphillips/stripefeeestimator

License

MIT