How to setup LnURLPay or Lightning Address the easiest way

I’d like to be receiving nostr tips on my own node, and need either LnURLPay or Lightning Address for that but I can’t figure out what is the simplest reliable way to do it. Can anybody provide step by step instructions?

5 Likes

If you have a domain name then you have your own custom address and with Fiatjaf’s Bridge Server, any sats sent to your adress will go directly to your node.

Borowing from both Dearthcoin’s tutorial (Pay to Lightning Address – Telegraph) and Fiatjaf’s bridge service (https://bridgeaddr.fiatjaf.com/)

Assuming you have the domain name inna.com want something like sats@inna.com to be your Lightning address, do the following.

  1. Ensure your Lightning node has ample in-bound liquidity!

  2. Obtain your node´s REST address.
    Login to your Umbrel.
    Open the Lightning Node app, in the upper right hand corner click the three dots, then Connect Wallet. Ensure the first dropdown is REST Tor. Then copy the lndconnect url
    The lndconnect url is formatted as such: lndconnect://toraddress.onion:8080?cert=gibberish&macaroon=gibberish

You’ll need to reformat the address a bit. First remove lndconnect, replace it with https . And remove everything after the port.
So the address should look like https://toraddress.onion:8080

  1. Create a Macaroon.
    Go to Thunderhub, click on Tools, then Bake under Macaroon
    Set Create to Invoices to Yes, ensure all the others are set to No
    Then click Bake To Macroon, copy that text
    For this example we’ll pretend it’s macroongibberish=

  2. Create the DNS records
    Each domain provider is different but you’ll need to create 4 records.
    For the CNAME record, enter @ for the host, and bridgeaddr.fiatjaf.com for the value.
    For one of the TXT records, enter _host for the host , and your node’s REST address for the value, https://toraddress.onion:8080
    For the second TXT record, _kind and lnd
    And for the third TXT record: _macaroon and the macaroon you just created, macroongibberish=

Screenshot below from my config using Namecheap. The text obscured in green is the tor address for the node (https://toraddress.onion:8080) and purple is the macaroon (macroongibberish=)

Wait roughtly 30 minutes for the DNS records to update and propogate.

  1. Send a test transaction using a seperate wallet. (Wallet of Satoshi , Breez, and the Bitcoin Beach/Jungle wallets all support Lighting Addresses.) Theoretically any text in front of inna.com but feel free to use whatever you want when you share the address to your Nostr profile.
3 Likes

Adding to this tutorial for if your domain name’s DNS tables has other records.
For example if you use it for a website or email, then the tutorial above might not work.

An alternative is to create a subdomain and use that for your Lightning Address.

So instead of whatever@inna.com as the Lightning Address, it could be something like whatever@sats.inna.com

The address you could then provide others to use to send you sats could then be stack@sats.inna.com :wink:

To do that, the CNAME record should use whatever you want your subdomain to be called under the Host field. For this example we’ll use sats

Then the rest of the TXT records hosts will need to have .sats after each host.
All values remain the same.

2 Likes

I have a domain on Hostgator that I am trying to get this to work on. Hostgator has a different zone editor which appends the domain to the ‘Host’ field which is labelled ‘Name’ I have setup a sub domain ‘lnd’ and I have tried a few different ways to enter the values. From the screenshot can anyone see what I might have wrong.