Setting up Valid Certificates for Neo4j with Let's Encrypt


(M. David Allen) #1

Hi everybody,

This question comes up fairly often, particularly in the cloud deployment world where we deploy instances of Neo4j with HTTPS open by default, and folks need valid certificates.

If you haven't used Let's Encrypt before, it's a free way of getting valid certificates for a host name you control. I wrote up the process of how to use Let's Encrypt with Neo4j, and how to install those certificates into your Neo4j instance.

Hope it's helpful!

(The Graph Giraffe) #2

Thanks for submitting!

I’ve added a tag that allows your blog to be displayed on the community home page!

(Tom) #3


This is more than helpful ! Certificates are the bane of even experienced system administrators and this document hands you the tools to do the job. Great stuff !


(Bcullen1974) #4

Hi David, Your article on using LetsEncrypt with Neo4j was fantastic. I have been trying to implement ssl on my neo4j backed website for a while now and this pulled it all together.

I'm not sure if this is the correct forum to post issues like this so feel free to direct me elsewhere if required.

I can access my website using https after installing the LetsEncrypt files as outlined in your article. However when I try to access the neo4j browser via it will not connect. I can access using standard http. I have checked the port is open on my firewall and I have gone through all the steps and checks as outlined. I suspect I may have something small incorrect in my neo4j.conf file as I have tried many options to get it working. I'm using a ubuntu 16.04 based server.

Would it be possible to take a look below and provide any suggestions? I would be eternally grateful!



(M. David Allen) #5

Ah, I just got finished writing you a response on Medium and now I see you've already posted here.

Your dbms.connector.https.listen_address=:7473 is a bit inconsistent, it shouldn't matter but you're missing the which binds to all network devices.

Everything else at first glance looks OK, which is why in the medium post I was requesting that you follow up with some specifics on what your browser is reporting.

Also, I take it as given that the certs you've installed are for (not some other domain) and that resolves to your machine? Is this cluster or standalone server?

(Bcullen1974) #6

Hi David,

Again thanks for your prompt response. The browser is just showing time out error ERR_CONNECTION_TIMED_OUT and no errors are showing in the console. The machine is a standalone server. I generated the scripts using the full URL and just used for example. If i use it opens the neo4j browser fine however using fails to load and times out.

Any ideas on what else I could check would be greatly appreciated. I'm at my wits end!



(Bcullen1974) #7

Hi David,

Again many thanks for your help on this topic. The browser is just showing a timed out error ERR_CONNECTION_TIMED_OUT and no error messages are appearing the Console. I have generated the certs using my own URL and only used for demo purposes. The machine is a standalone server.

Using accesses the neo4j browser fine, however times out as mentioned.

Any ideas on what else I could check would be greatly appreciated!

Thanks Again,


(M. David Allen) #8

I can't prove it, because it depends on the details of how you've deployed, but 99 times out of 100, connection timed out errors mean one of two things:

  • Your dbms.connector.https.enabled=false, and so you're not running https, and so neo4j isn't listening at all on that port.
  • Your local firewall rules don't permit traffic to port 7473.

The second explanation is the more likely one. By default, all clouds firewall all ports out. When you send traffic on those ports, the firewall at the cloud provider just drop your packets on the floor, and connection timeouts are how that manifests.

(Bcullen1974) #9

Hi David,

Apologies regarding double post.
I checked that port 7473 was open and it returned:

tcp6 0 0 :::7473 :::* LISTEN

I then tried two commands:
sudo ufw allow https
sudo ufw allow 443

Which seems to have added further rules to my firewall.

However the good news is that it now works!

Thanks again for your time and help in pointing me in the right direction.