Email without links?

In February last year I spent two months evaluating Invoice Ninja, there is much to like. In the end I abandoned attempts at migration because there appears to be an underlying assumption that there is a public URL associated with the installation of a self-hosted instance.

What I require is a completely private version of Invoice Ninja that sends out email with PDF attachments (or plain HTML) but without any links to any website, including links to payment confirmations.

Before I start this process again, is this actually possible, or was I correct in understanding that this is not supported?


I think it should work.

@david can you please confirm?

Note: you’d need to use SnapPDF/Headless Chromes to generate the PDFs locally.

@hillel I seem to recall a massive headache in getting PDF’s to generate last time. Running headless chrome seems to be a massive overhead just to generate a PDF.

I recall last time needing some magic combination of libraries and as I recall, it needed the web instance to have a DNS entry on the LAN so the PDF generation process could access it via URL - rather than or localhost within the Docker container.

I’m going from memory here, 14 or 15 months ago, so I may be misremembering.

I personally think Headless Chrome in an excellent solution, what would you suggest instead?


If you use a custom email design you can definitely send out emails any way you like with whatever content you choose.

In regards to PDF generation you have two options.

  1. Local generation with Snappdf.
  2. Use our Hosted PDF service which is free for White Label license holders.

@hillel, given that the invoice is generated as a HTML file - otherwise why would you need chrome, why not send it out as a HTML file and let the recipient render it on their end?

@david, I recall making a whole range of emails and removing the links, but I seem to recall payment received emails still going out with a link, rather than a PDF receipt.

I didn’t know you had a Hosted PDF service. How do you deal with data security since for that to work I’d have to send you an API call of some sort that contains private information.


You would need to also create a custom Payment Template much the same as the Invoice one.

In regards to our Hosted PDF solution, It is true that you would be POST’ing the raw HTML direct to one of our servers. We don’t store the information, it is converted and returned without it even hitting our hard drives.

Even better, the entire source code for this is online here: GitHub - invoiceninja/hosted-pdf so you could inspect the code there.

For reference the only lines for this code are:

		$pdf = $snappdf

    	return Response::make($pdf, 200, [
		    'Content-Type' => 'application/pdf',
		    'Content-Disposition' => 'inline; filename="ninja.pdf"'

@david, can I bypass the whole PDF adventure and attach a HTML invoice instead?

Most of our users require a PDF file, if you don’t need the PDF that’s a different question.

@onno, we don’t support html only invoices.

@david, @hillel Thank you both for your time and your prompt responses. Looks like I’m going to need to find a different solution.