This is not an HTTP port – How to solve this Elasticsearch exception

Opster Team

August-23, Version: 6.8-8.9

Briefly, this error occurs when Elasticsearch is trying to connect to a port that is not configured to handle HTTP requests. This could be due to incorrect configuration settings or a network issue. To resolve this, you can check your Elasticsearch configuration file (elasticsearch.yml) to ensure the correct port is specified. Also, verify that your network settings allow HTTP traffic on the specified port. If you’re running a firewall, ensure it’s not blocking the HTTP port. Lastly, ensure that no other service is using the same port.

This guide will help you check for common problems that cause the log ” This is not an HTTP port ” to appear. To understand the issues related to this log, read the explanation below about the following Elasticsearch concepts: .

Log Context

Log “This is not an HTTP port” class name is We extracted the following from Elasticsearch source code for those seeking an in-depth context :

 }  private static int readHeaderBuffer(BytesReference headerBuffer) throws IOException {
 if (headerBuffer.get(0) != 'E' || headerBuffer.get(1) != 'S') {
 if (appearsToBeHTTPRequest(headerBuffer)) {
 throw new HttpRequestOnTransportException("This is not an HTTP port");
 }  if (appearsToBeHTTPResponse(headerBuffer)) {
 throw new StreamCorruptedException(
 "received HTTP response on transport port; ensure that transport port (not "


How helpful was this guide?

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?