Do not add "http://" prefix to exotic URLs in <a href

I wanted to add LNURL payment link, so the link opens wallet app, but Webflow does not recognise "lightning:" prefix as a valid URL, so it adds "http://" and brakes the link.

I expect Webflow brakes a lot of exotic URLs like this. Would be good to expect designers can use anything.

Yes, it is nice to fix mistakes when people try to set href to something like "" which is not valid URL, but strings what are valid URL, but not having whitelisted URL handler should be allowed.

Solution is to validate URL format (with any protocol) or to just warn designer when using exotic prefix.


  1. Write your URL to a custom attribute data-href

  2. Add embed element after the broken links or to end of the page:

document.querySelectorAll('[data-href]').forEach(a => { a.href = a.dataset.href })

  • Fakt
  • Nov 19 2021