A Lightning Network invoice is a payment request used to receive Bitcoin through the Lightning Network. It contains the information a Lightning wallet needs to send a specific amount of Bitcoin to a recipient quickly and with very low fees.
Unlike a traditional Bitcoin address, a Lightning invoice is generally created for a specific payment and includes details such as the payment amount, recipient information, and an expiration time.
What Is the Lightning Network?
The Lightning Network is a Layer 2 payment network built on top of Bitcoin. It is designed to make Bitcoin payments faster and cheaper by allowing transactions to take place off the Bitcoin blockchain.
Instead of recording every small payment directly on the Bitcoin blockchain, users can make payments through Lightning channels. The final settlement can later be recorded on Bitcoin’s main blockchain.
This makes Lightning particularly useful for small and frequent Bitcoin payments.
What Is a Lightning Network Invoice?
A Lightning Network invoice is a digitally generated payment request.
When someone wants to receive Bitcoin through Lightning, their wallet can generate an invoice. The sender then scans a QR code or copies the invoice into their Lightning wallet and pays it.
A Lightning invoice usually contains information such as:
- The amount to be paid
- A payment hash
- An expiration time
- Information identifying the payment request
- A cryptographic signature
Lightning invoices are commonly represented as a long text string beginning with prefixes such as lnbc for Bitcoin mainnet payments.
For example, a Lightning invoice may look something like:
lnbc...
The actual invoice is much longer and contains encoded payment information.
How Does a Lightning Invoice Work?
The process is relatively simple.
1. The recipient creates an invoice
The person or business receiving Bitcoin opens a Lightning wallet and enters the amount they want to receive.
The wallet generates a Lightning invoice.
2. The sender receives the invoice
The sender can receive the invoice as text or as a QR code.
For example, an online store might display a QR code after a customer chooses Bitcoin Lightning as the payment method.
3. The sender pays the invoice
The sender opens their Lightning wallet, scans the QR code or pastes the invoice, and confirms the payment.
The Lightning Network then finds a route for the payment.
4. The payment is completed
If a suitable route is available and the required liquidity exists, the payment can usually settle within seconds.
The recipient’s wallet recognizes that the invoice has been paid.
What Information Is Inside a Lightning Invoice?
A Lightning invoice isn’t simply a Bitcoin address. It is an encoded payment request containing several pieces of information.
Some of the important components include:
Payment Amount
The invoice can specify exactly how much Bitcoin should be paid.
For example, a merchant could create an invoice requesting 0.0001 BTC.
Payment Hash
The invoice contains information used to identify and verify the payment.
The underlying payment mechanism uses a cryptographic secret known as a preimage, which plays an important role in confirming that the intended payment has been completed.
Expiration Time
Lightning invoices can expire.
For example, a merchant may generate an invoice that remains valid for only a limited period. If it expires before payment, the customer may need to request a new invoice.
Description
An invoice can also include a description explaining what the payment is for.
For example:
Order #12345
This can help merchants and customers identify payments.
Signature
The invoice is cryptographically signed so that the receiving wallet can verify its authenticity.
Lightning Invoice vs. Bitcoin Address
A Lightning invoice and a traditional Bitcoin address serve different purposes.
| Feature | Lightning Invoice | Bitcoin Address |
|---|---|---|
| Network | Lightning Network | Bitcoin blockchain |
| Typical use | Specific payment request | Receiving on-chain Bitcoin |
| Amount | Can specify amount | Usually amount is provided separately |
| Expiration | Can expire | Does not normally expire |
| Payment speed | Usually seconds | Depends on blockchain confirmation |
| Fees | Usually very low | Typically higher than Lightning for small payments |
| Reusable | Generally intended for a single payment | Can be reused, although address reuse is discouraged |
One important difference is that Lightning invoices are generally designed for individual payments, while Bitcoin addresses can be used as destinations for on-chain transactions.
What Is a Lightning Invoice QR Code?
A Lightning invoice can be converted into a QR code.
This makes payments easier because the sender doesn’t have to manually copy a long string of characters.
For example, a coffee shop accepting Bitcoin through Lightning might display:
Pay with Bitcoin Lightning → Scan QR Code
The customer scans the code with a compatible Lightning wallet, reviews the payment details, and confirms the transaction.
Are Lightning Invoices Reusable?
Generally, no.
A Lightning invoice is normally created for a particular payment. Once it has been paid, it should not be treated like a reusable Bitcoin address.
If a merchant needs to receive another payment, their payment system will typically generate a new Lightning invoice.
This approach also helps merchants associate each payment with a particular order or customer.
Can You Pay a Lightning Invoice With Regular Bitcoin?
Not directly.
A Lightning invoice is designed for a payment over the Lightning Network. A standard Bitcoin on-chain transaction cannot simply be sent to a Lightning invoice.
However, some modern wallets and exchanges can handle the conversion or routing automatically.
For example, a wallet may allow a user to pay a Lightning invoice using funds that are ultimately sourced from their Bitcoin balance.
The exact functionality depends on the wallet or service being used.
What Happens If a Lightning Invoice Expires?
If a Lightning invoice expires before it is paid, the recipient usually needs to create a new invoice.
An expired invoice should not be treated as a valid payment request.
This is one reason merchants and payment systems often generate invoices dynamically when a customer begins the checkout process.
Are Lightning Network Invoices Safe?
Lightning invoices use cryptographic mechanisms to authenticate payment requests and settle payments through the Lightning Network.
However, users should still verify the payment information before confirming a transaction.
Before paying an invoice, check:
- The requested amount
- The recipient or payment description
- The invoice expiration
- The wallet or service requesting payment
If you receive an unexpected Lightning invoice, don’t pay it simply because someone sent you a QR code or payment string.
Why Are Lightning Invoices Useful?
Lightning invoices make Bitcoin payments easier for businesses, applications, and individuals.
They can be useful for:
- Online stores
- Freelancers
- Content creators
- Donations
- Digital products
- Small Bitcoin payments
- Gaming applications
- Bitcoin tipping
- Recurring payment systems where new invoices are generated
Because Lightning payments can be fast and inexpensive, invoices are particularly useful for transactions where using Bitcoin’s main blockchain would be inconvenient.
Lightning Invoice Example
Imagine you run an online store and sell a digital product for $10.
You decide to accept Bitcoin through Lightning.
Your payment system can:
- Calculate the Bitcoin amount equivalent to $10.
- Generate a Lightning invoice.
- Display the invoice as a QR code.
- Give the customer a limited amount of time to pay.
- Detect when the invoice has been paid.
- Automatically deliver the digital product.
The customer doesn’t need to wait for a traditional Bitcoin blockchain confirmation before the payment can be recognized by the Lightning payment system.
Frequently Asked Questions
What is a Lightning Network invoice?
A Lightning Network invoice is a payment request used to receive Bitcoin through the Lightning Network. It contains information such as the payment amount, payment hash, expiration time, description, and cryptographic signature.
How do I pay a Lightning invoice?
Open a Lightning-compatible Bitcoin wallet, scan the invoice QR code or paste the invoice text, review the payment details, and confirm the payment.
How long does a Lightning invoice last?
The expiration period depends on how the invoice was created. Many Lightning invoices are designed to remain valid for a limited period, after which a new invoice may need to be generated.
Can I reuse a Lightning invoice?
Lightning invoices are generally intended for a specific payment rather than repeated use. A new invoice is normally generated for each payment.
Does a Lightning invoice contain Bitcoin?
No. A Lightning invoice is a payment request, not Bitcoin itself. The Bitcoin is transferred when the invoice is successfully paid.
Is a Lightning invoice the same as a Bitcoin address?
No. A Bitcoin address is used for on-chain Bitcoin transactions, while a Lightning invoice is a payment request for the Lightning Network.
Conclusion
A Lightning Network invoice is essentially a digital payment request for receiving Bitcoin over the Lightning Network. It allows the recipient to specify payment information such as the amount, description, and expiration while providing the sender with an easy way to make the payment.
For Bitcoin users and businesses, Lightning invoices provide a convenient way to request and receive fast, low-cost Bitcoin payments without requiring every transaction to be recorded directly on the Bitcoin blockchain.