[Ethereum] How To SSL Ethereum Geth Node


I have a geth node up and running but I want to be able to connect to it via https. For example https://eth-node-domain.com:8545 or How can I go about doing this? I have been google searching for the past week but cant seem to find anything about this.

I am running Ubuntu on digital ocean

I have tried to install lets encrypt cert but that did not work.

sudo add-apt-repository ppa:certbot/certbot
sudo apt-get update
sudo apt-get install certbot
sudo certbot certonly --standalone -d mynodesite.com

Best Answer

Setup nginx as proxy server for your node below script for your reference

server {

listen 443 default_server;
server_name your.domain.com;

ssl on;
ssl_certificate /usr/local/nginx/conf/server.pem;
ssl_certificate_key /usr/local/nginx/conf/server.key;
ssl_session_cache shared:SSL:10m;

location / {

    proxy_pass http://localhost:8545; # my existing apache instance
    proxy_set_header Host $host;

    # re-write redirects to http as to https, example: /home
    proxy_redirect http:// https://;
Related Topic