# How to send one-time invoices in Stripe

- Tool: Stripe
- Difficulty: Beginner
- Time required: 15 minutes
- Compatibility: Stripe API v2024-12+, Node.js 18+
- Last updated: March 2026

## TL;DR

Send one-time invoices in Stripe through the Dashboard (Billing → Invoices → Create invoice) or the API by creating an invoice item, then creating and sending the invoice. The customer receives an email with a payment link. You can set due dates, add line items, attach metadata, and collect payment automatically. All amounts are in cents.

## Sending One-Time Invoices in Stripe

Stripe invoices aren't just for subscriptions — you can send one-time invoices for project work, consulting fees, custom orders, or any ad-hoc payment. The invoice includes a payment link so your customer can pay online with a card or other payment method. You can create invoices manually through the Dashboard or programmatically via the API for automated billing flows.

## Before you start

- A Stripe account in test mode
- A customer created in Stripe (or their email address)
- Node.js 18+ for API examples

## Step-by-step guide

### 1. Create an invoice from the Dashboard

Go to Stripe Dashboard → Billing → Invoices → Create invoice. Select an existing customer or enter a new email address. Add line items with descriptions and amounts. Set the due date, memo, and footer. Click 'Review invoice' then 'Send invoice'. The customer receives an email with a payment link.

**Expected result:** An invoice is created and emailed to the customer with a hosted payment page.

### 2. Create a customer via API (if needed)

If the customer doesn't exist in Stripe yet, create one first. You need a customer object before you can attach invoice items.

```
const stripe = require('stripe')(process.env.STRIPE_SECRET_KEY);

const customer = await stripe.customers.create({
  email: 'client@example.com',
  name: 'Jane Smith',
  metadata: { project: 'Website Redesign' },
});
```

**Expected result:** A new customer is created in Stripe with an ID like cus_abc123.

### 3. Add invoice items

Create one or more invoice items attached to the customer. These will appear as line items on the invoice. Amounts are in cents (2000 = $20.00).

```
// Add line items
await stripe.invoiceItems.create({
  customer: customer.id,
  amount: 50000,        // $500.00
  currency: 'usd',
  description: 'Website design — homepage and 3 subpages',
});

await stripe.invoiceItems.create({
  customer: customer.id,
  amount: 15000,        // $150.00
  currency: 'usd',
  description: 'Logo design and branding package',
});
```

**Expected result:** Two invoice items are created and attached to the customer, ready to be bundled into an invoice.

### 4. Create and send the invoice

Create the invoice object, which automatically includes all pending invoice items for the customer. Set the due date and any optional fields, then send it.

```
const invoice = await stripe.invoices.create({
  customer: customer.id,
  collection_method: 'send_invoice',
  days_until_due: 30,
  description: 'Website redesign project — Phase 1',
  footer: 'Thank you for your business!',
});

// Finalize the invoice (locks the line items)
const finalized = await stripe.invoices.finalizeInvoice(invoice.id);

// Send the invoice email to the customer
const sent = await stripe.invoices.sendInvoice(invoice.id);

console.log('Invoice sent:', sent.hosted_invoice_url);
```

**Expected result:** The invoice is finalized and emailed to the customer. They receive a payment link where they can pay online.

### 5. Track invoice payment status

Monitor the invoice status via the Dashboard or API. Invoices go through these statuses: draft → open (sent) → paid (or void/uncollectible).

```
const invoice = await stripe.invoices.retrieve('in_abc123');
console.log('Status:', invoice.status);       // draft, open, paid, void, uncollectible
console.log('Amount due:', invoice.amount_due / 100);
console.log('Amount paid:', invoice.amount_paid / 100);
```

**Expected result:** You can check whether the invoice has been paid, is still open, or needs follow-up.

## Complete code example

File: `send-invoice.js`

```javascript
require('dotenv').config();
const stripe = require('stripe')(process.env.STRIPE_SECRET_KEY);

async function sendOneTimeInvoice({ email, name, items, daysUntilDue = 30, memo }) {
  // 1. Create or find customer
  let customer;
  const existing = await stripe.customers.list({ email, limit: 1 });

  if (existing.data.length > 0) {
    customer = existing.data[0];
  } else {
    customer = await stripe.customers.create({ email, name });
  }

  // 2. Add invoice items
  for (const item of items) {
    await stripe.invoiceItems.create({
      customer: customer.id,
      amount: item.amount,  // in cents
      currency: item.currency || 'usd',
      description: item.description,
    });
  }

  // 3. Create invoice
  const invoice = await stripe.invoices.create({
    customer: customer.id,
    collection_method: 'send_invoice',
    days_until_due: daysUntilDue,
    description: memo || '',
    footer: 'Thank you for your business!',
  });

  // 4. Finalize and send
  await stripe.invoices.finalizeInvoice(invoice.id);
  const sent = await stripe.invoices.sendInvoice(invoice.id);

  return {
    id: sent.id,
    number: sent.number,
    amount_due: sent.amount_due,
    hosted_url: sent.hosted_invoice_url,
    pdf_url: sent.invoice_pdf,
    status: sent.status,
  };
}

// Example usage
sendOneTimeInvoice({
  email: 'client@example.com',
  name: 'Jane Smith',
  items: [
    { amount: 50000, description: 'Website design — homepage + 3 pages' },
    { amount: 15000, description: 'Logo design package' },
  ],
  daysUntilDue: 30,
  memo: 'Website redesign project — Phase 1',
}).then(result => {
  console.log('Invoice sent:', result);
}).catch(console.error);
```

## Common mistakes

- **Forgetting to finalize the invoice before sending** — undefined Fix: Call stripe.invoices.finalizeInvoice(id) before sendInvoice(). Sending a draft invoice will throw an error.
- **Using amounts in dollars instead of cents** — undefined Fix: All Stripe amounts are in the smallest currency unit. For USD, pass 5000 for $50.00. For JPY, pass the full amount (no conversion needed).
- **Using collection_method: 'charge_automatically' when you want the customer to pay manually** — undefined Fix: Use 'send_invoice' for invoices where the customer pays via the hosted link. 'charge_automatically' immediately charges the card on file.
- **Creating invoice items without a customer** — undefined Fix: Invoice items must be attached to a customer. Create the customer first, then create invoice items with the customer ID.

## Best practices

- Use descriptive line item descriptions so customers know exactly what they're paying for
- Set a reasonable due date — 15 or 30 days is standard for most businesses
- Include a professional memo and footer on your invoices
- Use metadata to track internal references like project IDs or PO numbers
- Monitor invoice.payment_succeeded webhooks to trigger fulfillment automatically
- Send reminders for unpaid invoices using Stripe's built-in reminder settings
- Test the full invoice flow in test mode using the 4242424242424242 card

## Frequently asked questions

### Can I send a Stripe invoice without a subscription?

Yes. One-time invoices work independently of subscriptions. Create invoice items for the customer, then create and send the invoice. The customer pays via a hosted payment page.

### How does the customer pay a one-time invoice?

The customer receives an email with a link to a Stripe-hosted payment page. They can pay with a credit card, debit card, or other enabled payment methods. No Stripe account is needed.

### Can I auto-charge a customer's card instead of sending an invoice?

Yes. Set collection_method to 'charge_automatically' instead of 'send_invoice'. This charges the customer's default payment method immediately when the invoice is finalized.

### How do I add tax to a one-time invoice?

Use Stripe Tax or add tax rates manually. When creating invoice items, you can attach a tax_rates array. Or enable Stripe Tax in Dashboard → Settings → Tax to calculate automatically.

### Can I edit an invoice after sending it?

No. Once finalized and sent, invoices are immutable. You can void the invoice and create a new one, or issue a credit note for partial adjustments.

---

Source: https://www.rapidevelopers.com/stripe-guide/how-to-send-one-time-invoices-in-stripe
© RapidDev — https://www.rapidevelopers.com/stripe-guide/how-to-send-one-time-invoices-in-stripe
