Ошибка 505 html

Если ваш сайт отзывается ошибкой, то это верный путь потерять потенциального посетителя. Поэтому так важно анализировать любые ошибки, с которыми сталкиваются пользователи и пытаться их исправить. Причем независимо от того, на чьей стороне возникает сбой.

В этот раз подробно расскажу об ошибке 505. Почему появляется, кто виноват и что предпринять.

Что обозначает ошибка 505?

Это серверная ошибка (как и все под номерами 5хх). С помощью нее сервер пытается сообщить, что он не поддерживает HTTP-протокол, который использует клиент. 

То есть в запросе клиента указана версия HTTP 1.1 или какая-нибудь еще более старая (типа HTTP 0.9). Ресурс с ней больше не работает или не хочет обрабатывать «устаревший» запрос. Отсюда и возникает ошибка. 

По идее, разработчики должны указать клиенту не только код ошибки, но и пояснить, почему она возникла. Объяснить, почему не поддерживается выбранный HTTP-протокол. Но это уже частности, которые не всегда берутся во внимание. Вебмастерам и администраторам на заметку, так сказать. Поясните, пожалуйста, пользователям, почему надо обновляться и зачем нужен более свежий протокол HTTP.

Ошибка сервера 505Но это не единственный сценарий. То же справедливо и для владельцев сайта. Возможно, это они давно не обновляли программное обеспечение сервера. Поэтому ресурс не работает с новыми версиями протокола. Что тоже ведет к аналогичной ошибке. 

Ну или разработчики решили в угоду безопасности и прогресса попросту отказаться от всего, что старее HTTP 1.1. Поэтому свежий браузер может не пустить на старинный сайт. В любом случае отстает кто-то один. Нужно устранить эту несовместимость.

Как исправить 505 HTTP Version not Supported?

Ок, теперь мы знаем, что обозначает код 505 и понимаем, из-за чего он возникает. Дело в несоответствии версий протоколов. Теперь будем разбираться, как устранить возникшую проблему. Рассмотрим варианты как для пользователей, так и для владельцев ресурса.

Что можно сделать на стороне клиента?

Начнем с основ.

Обновить программное обеспечение

Обновление приложений, драйверов, системы и прочих кусков «софта» нередко решает проблемы. Могу посоветовать попробовать обновление и в этой ситуации. 

  • Скачайте обновление операционной системы.

  • Обновите браузеры и все используемые веб-приложения. Так можно будет сразу отмести в сторону проблемы с устаревшим ПО на стороне клиента.

  • Переустановите протокол NET.Framework.

  • Установите новые драйвера для сетевых устройств.

  • Выдайте используемому браузеры больше прав в брандмауэре и антивирусе.

В общем, выполняем базовую диагностику и задействуем «универсальные» методы устранения всех проблем и ошибок в компьютере. Как это обычно и бывает, да.

Удалить мусор из браузера или переустановить его

Возможно, проблема в браузере. Попробуем удалить весь накопившийся мусор, включая куки-файлы и кэш. 

В браузере Google Chrome это делается так:

  • Открываем настройки браузера.

  • Переходим в раздел «Конфиденциальность и безопасность».

  • Выбираем «Файлы cookie и другие данные».

  • Нажимаем на кнопку «Удалить все».

В других браузерах немного отличаются названия меню, но принцип остается тот же.

Чтобы окончательно убедиться, что в браузере не осталось мусора, можно удалить его с жесткого диска и установить повторно.

Просить о помощи интернет-провайдера

Если код 505 наблюдается во всех браузерах, во всех интернет-приложениях и на каждом сайте, то следует обратиться за помощью к провайдеру. Вероятно, проблема где-то на его стороне, и мучить браузеры с операционной системой вовсе не стоит. 

Ничего не помогло? У провайдера все без эксцессов? Браузер новый, а один из сайтов все равно выдает 505 ошибку? Виноваты держатели ресурса.

Как исправить ошибку на стороне сервера?

С клиентом разобрались, теперь переходим к более вероятному виновнику появления сбоев и пробуем устранить ошибку.

Обновляем программное обеспечение сервера

Браузеры уверены в том, что существующие интернет-ресурсы поддерживают HTTP версии 1.1 и новее. Ваш не в их числе? Пора исправляться. Пора бы уже обновить и прокачать свой ресурс, приведя сайт в рабочее состояние.

Http

Перенастраиваем сервер

Даже на относительно новых серверах могут быть выставлены неправильные настройки. Взгляните на то, какие запросы может принимать ваш сайт. Какие требования он предъявляет к каждому запросу. Возможно, он настроен так, что не готов принимать запросы от браузеров, требующих протокол старше 0.9.

Меняем хостинг

Ладно, необязательно сразу так грубо и резко. Для начала обратитесь в отдел технической поддержки. Вам наверняка могут там помочь. Если нет, то смело переезжайте на какой-нибудь внятный хостинг. Например, на Timeweb. Сможете без проблем перенести все ресурсы. Получите устойчивый к сбоям и падениям хостинг, грамотную техподдержку, избыток ресурсов. Все полезное и нужное.

Это, пожалуй, все. Теперь вы знаете, что означает ошибка 505 и какие меры можно предпринять, чтобы ее устранить. Главное, сделать это побыстрее, чтобы не мучить и себя, и посетителей ресурса (если вы его владелец).

HTTP response status code 505 HTTP Version Not Supported is a server error message that indicates the server is unwilling to process the HTTP request using the major version of HTTP that was used in the HTTP request message.

Usage

When the 505 HTTP Version Not Supported status code is received, it means that the server does not support the major protocol used by the HTTP request. The server is expected to generate a HTTP response indicating why the specific HTTP protocol is not supported and also list which HTTP protocols the server is willing to accept at this URI.

Example

In the example, the client requests a resource and the server responds with a 505 HTTP Version Not Supported status code because it does not support HTTP/3.

Request

GET / HTTP/3
Host: www.example.ai

Response

HTTP/1.1 505 HTTP Version Not Supported
Content-Type: text/html; charset=UTF-8
Content-Length: 150

<html>
  <head>
    <title>Protocol Not Supported<title>
  </head>
  <body>
    <p>HTTP/3 not supported. Please use HTTP/1.1.</p>
  </body>
</html>

Code references

.NET

HttpStatusCode.HttpVersionNotSupported

Rust

http::StatusCode::HTTP_VERSION_NOT_SUPPORTED

Rails

:http_version_not_supported

Go

http.StatusHTTPVersionNotSupported

Symfony

Response::HTTP_VERSION_NOT_SUPPORTED

Python3.5+

http.HTTPStatus.VERSION_NOT_SUPPORTED

Java

java.net.HttpURLConnection.HTTP_VERSION

Apache HttpComponents Core

org.apache.hc.core5.http.HttpStatus.SC_HTTP_VERSION_NOT_SUPPORTED

Angular

@angular/common/http/HttpStatusCode.HttpVersionNotSupported

Takeaway

The 505 HTTP Version Not Supported status code is a server error that is generated when the server is unable or unwilling to process a HTTP request because it does not support the HTTP protocol that was used to submit it.

See also

  • RFC 7231

Last updated: June 29, 2022

What is HTTP 505 Error?

A 505 error, also known as HTTP Version Not Supported, is a server-side error that occurs when the server does not support the HTTP protocol version used by the client.

The server understands the request but cannot fulfill it due to the incompatible protocol version. The HTTP 505 error is one such error that is cryptic and perplexing, seemingly appearing out of nowhere. It differs from other server errors like 500 Internal Server Error or 502 Bad Gateway, which indicate different issues.

Understanding 505 errors is essential for web developers, system administrators, and users to diagnose and troubleshoot issues related to communication between clients and servers.

Since there have been not many resources available online about the HTTP 505 error. We are providing you with a comprehensive guide, explaining its meaning and the best ways to fix it.

Let us check them out!



Understanding the 5xx Series of HTTP Status Codes

The 5xx series of HTTP status codes indicate server-side errors. These errors occur when the server encounters a problem fulfilling the client’s request. Common causes of server errors include misconfigurations, software bugs, and overload. The 5xx status codes notify the client that the server is unable to handle the request properly.


Read: 🚩 14 Most Common WordPress Errors and their quick Solutions


Causes of a 505 Error

A 505 error can occur due to various reasons:

  • Outdated or unsupported HTTP protocol versions: The server may not support older or obsolete versions of the HTTP protocol, resulting in a 505 error.
  • Incompatibility between client and server versions: The client may be using a newer or unrecognized version of the HTTP protocol, which the server cannot handle.
  • Server misconfiguration or software bugs: Improper server configuration or software bugs can lead to a 505 error when processing HTTP requests.
  • Examples of situations leading to a 505 error: For instance, if a client sends an HTTP/2 request to a server that only supports HTTP/1.1, a 505 error will occur.
  • If there is any whitespace after the HTTP version.
  • If the client is other than a web browser.

How a 505 Error is Handled?

When a server encounters a 505 error, it sends a response to the client indicating the unsupported protocol version. The client may display an error message or take appropriate action based on the received response.

The impact on the user experience can vary depending on the specific application or website. Users encountering a 505 error are advised to check their internet connection, clear their browser cache, and contact the website administrator if the issue persists.

Here is an example for your reference,

HTTP/1.1 505 HTTP Version Not Supported
Server: cloudflare
Date: Mon, 15 Aug 2023 12:22:25 GMT
Content-Type: text/plain
Content-Length: 44
The HTTP protocol version used is not supported.

In the above example, the server responds with a 505 status code, indicating that the HTTP version used in the request is not supported. The response includes a simple text message informing the client that the HTTP protocol version is not recognized or supported by the server.

The Content-Type header specifies the type of content being returned (text/plain in this case), and the Content-Length header indicates the length of the response body.


To troubleshoot and resolve 505 errors, website administrators and developers can follow these steps:

  • Verify server configuration: Check if the server is correctly configured to support the required HTTP protocol versions.
  • Check HTTP protocol versions: Ensure that the client and server are using compatible HTTP protocol versions.
  • Update server software or modules: Keep the server software and modules up to date to support the latest HTTP protocol versions.
  • Test compatibility between client and server versions: Perform compatibility tests between the client and server to ensure they can communicate properly.
  • Switch to a modern Browser: Try to access your favorite website on a new modern browser and see If the error goes away.
  • No whitespace: It is important to ensure that there is no whitespace after the HTTP version, as it can potentially trigger the 505 error
  • Try a proxy server: If upgrading the server or moving to a supported protocol version is not possible, an alternative approach is to utilize a proxy server that is compatible with the required protocol version. This way, the proxy server will handle all the requests on behalf of the original server and forward the response to the client.
  • Get help from the server admin: If none of the above troubleshooting methods work, the last thing you can do is approach your server admin and get help from them directly.

In general, the key to fixing 505 errors is to ensure that the client and the server are using compatible versions of protocols.


Best Practices to Prevent 505 Errors

It is often said, “Prevention is better than cure,” and it is best to follow preventive practices initially to minimize future issues.

Check out the best preventive steps you can follow.

1. Keep server software up to date: Regularly update the server software and modules to ensure they support the latest HTTP protocol versions. Stay informed about security patches and bug fixes provided by the software vendors.

2. Ensure compatibility between client and server versions: Before deploying any updates or changes, thoroughly test the compatibility between the client and server. Verify that both ends can understand and handle the same HTTP protocol version.

3. Perform regular testing and monitoring: Implement a testing and monitoring strategy to identify any potential issues related to HTTP protocol compatibility. Regularly test the communication between clients and servers to catch and resolve compatibility problems early on.

4. Utilize version negotiation techniques: Implement version negotiation techniques such as HTTP content negotiation or feature detection mechanisms to establish the most appropriate and compatible protocol version between the client and server.

By following these best practices you can minimize the occurrence of 505 errors and be able to deliver a smooth and reliable user experience.


Wrapping up

To create a smooth, robust, and error-Free web infrastructure, it is always recommended to first find out the underlying cause of the error and on the basis of that the right approach to fix it with the right approach.

Simply put, the 505 error code meaning is there is the server does not support or recognize the HTTP protocol version used by the client.

By identifying the causes of these errors, such as outdated protocol versions or server misconfigurations, and following best practices like keeping server software up to date and ensuring compatibility, administrators can prevent and resolve 505 errors effectively.

In addition to that, Regular testing, monitoring, and implementing version negotiation techniques further enhance the ability to handle HTTP protocol version discrepancies.

By addressing 505 errors with the right approach, you can provide your users with a seamless experience, ensure smooth applications function, and able to deliver better user satisfaction.

Additionally, please let us know in the comment section below which troubleshooting method helped you fix this issue.


Frequently Asked Questions

How do I fix HTTP error 505?

You can fix HTTP error 505, by following these methods:
1. Verify server configuration
2. Check HTTP protocol versions
3. Update server software or modules
4. Test compatibility between client and server versions
5. Switch to a modern Browser
6. No whitespace
7. Try a proxy server
8. Get help from your server admin

What is 404 and 505 error?

The 404 error occurs when the requested resource is not found, while the 505 error indicates an unsupported HTTP protocol version

What is a 505 gateway error?

A 505 error occurs when the client uses an unsupported HTTP protocol version with the server. It’s different from gateway errors like 502 or 504.


The server does not support, or refuses to support, the major version of HTTP that was used in the request message.

The server is indicating that it is unable or unwilling to complete the request using the same major version as the client, as described in Section 2.6 of RFC7230, other than with this error message. The server SHOULD generate a representation for the 505 response that describes why that version is not supported and what other protocols are supported by that server.


  • Source: RFC7231 Section 6.6.6

505 CODE REFERENCES

Rails HTTP Status Symbol :http_version_not_supported

Go HTTP Status Constant http.StatusHTTPVersionNotSupported

Symfony HTTP Status Constant Response::HTTP_VERSION_NOT_SUPPORTED

Python2 HTTP Status Constant httplib.VERSION_NOT_SUPPORTED

Python3+ HTTP Status Constant http.client.VERSION_NOT_SUPPORTED

Python3.5+ HTTP Status Constant http.HTTPStatus.VERSION_NOT_SUPPORTED

.NET HttpStatusCode.HttpVersionNotSupported

Rust http::StatusCode::HTTP_VERSION_NOT_SUPPORTED

Java java.net.HttpURLConnection.HTTP_VERSION

Apache HttpComponents Core org.apache.hc.core5.http.HttpStatus.SC_HTTP_VERSION_NOT_SUPPORTED

Angular @angular/common/http/HttpStatusCode.HttpVersionNotSupported

505 status code example

Here is an example of a request and response that could result in a 505 HTTP Version Not Supported status code:

Request

PUT /example HTTP/2.0
Host: www.example.com
Content-Type: text/plain
Content-Length: 42

Hello, this is an example request body.

Response

HTTP/1.1 505 HTTP Version Not Supported
Date: Wed, 24 Mar 2023 14:28:00 GMT
Server: Apache/2.4.48 (Unix)
Connection: close
Content-Type: text/html; charset=iso-8859-1

<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html>
<head>
<title>505 HTTP Version Not Supported</title>
</head>
<body>
<h1>HTTP Version Not Supported</h1>
<p>The server does not support the HTTP protocol version used in the request.</p>
</body>
</html>

In this example, the client is attempting to use the HTTP/2.0 protocol to send a PUT request to the server. However, the server only supports the HTTP/1.1 protocol, so it responds with a 505 HTTP Version Not Supported status code. The response also includes a message explaining that the server does not support the HTTP protocol version used in the request.

How to fix a 505 status code

If you receive a 505 HTTP Version Not Supported status code, it means that the HTTP protocol version used in the request is not supported by the server. Here are a few ways to address this issue:

  • Check the protocol version: The first step is to ensure that you are using a supported protocol version. HTTP/1.1 is the most widely used protocol version, and most servers support it. If you are using a different version, try switching to HTTP/1.1 and see if the error goes away.
  • Update the server: If the server does not support the protocol version you need, consider upgrading the server to a version that supports it. Alternatively, you can check if there is a patch or plugin available that adds support for the required protocol version.
  • Use a proxy server: If you are unable to upgrade the server or switch to a supported protocol version, you can use a proxy server that supports the desired protocol version. The proxy server will handle the request on your behalf and forward the response back to you.
  • Contact the server administrator: If you have tried the above solutions and still cannot resolve the issue, contact the server administrator for assistance. They may be able to provide additional information or suggest a workaround.

In general, resolving a 505 HTTP Version Not Supported error involves ensuring that the client and server are using compatible protocol versions.

What is the difference between a 500 status code and a 505 status code?

A 500 Internal Server Error status code indicates that the server encountered an unexpected condition that prevented it from fulfilling the request. This error can occur due to a variety of reasons, such as a programming error, an insufficient system resource, or a misconfiguration of the server.

On the other hand, a 505 HTTP Version Not Supported status code indicates that the server does not support the HTTP protocol version used in the request. This error occurs when the client attempts to use an HTTP protocol version that the server does not recognize or support.

Additional resources

  • Learn about web development
  • Learn about SEO
  • Web development services from WebFX
  • SEO services from WebFX
  • MDN Web Docs
  • W3Schools

Return to List of HTTP Status Codes

Errors aren’t exactly fun and that goes double for esoteric error codes you can’t make heads or tails of. Error 505 is a cryptic and confusing example that can show up in unexpected places, like the outgoing links on your WordPress website. Since there are no comprehensive articles about this online, we have decided to settle the issue once for all. Let’s take a look at the 505 error code meaning and how to resolve it. 

505 Error Code Meaning Revealed

[Error in Explorer]

[Error in Explorer]

As you may well know, HTTP and HTTPS are protocols that tell browsers and apps how to communicate with web servers. This starts with the client sending a request to a specified server and the server, in turn, answering the request. Now, there are a lot of things that can go wrong in this exchange. To help troubleshoot problems, HTTP implements a series of error codes that tell you where and why the problem arose. These codes fall into different categories, usually distinguished by the left-most numeral of the code. The 5XX error codes are server errors, which means the problem is on the server-side of the exchange. You may have already seen the common 504 Gateway Timeout error, for example.

Error 505 is code for “HTTP Version not Supported,” and this means that the client’s request uses a version of HTTP that the server doesn’t recognize. Most of the time, the problem is that the web server is using an old HTTP version. That can happen when web servers like Apache or Nginx have not been updated for a long time.

Sometimes, however, the opposite is the case. If you use older browsers like Internet Explorer for newer websites, there’s a chance you’ll see error 505 a lot. In this case, the problem is not HTTPserver’s, even though it is called a server error.

Now, there are some ways you can avoid this error, depending on whether you have access to the server or not. Let’s dive right in.

Effective Ways to Resolve HTTP 505 Error

How to Resolve HTTP 505 Error: Client-Side Solutions

If you’re seeing error 505 in your browser, there are two quick ways to fix it. The first thing to do is to see if you’re using a really old browser like Microsoft’s Internet Explorer, for example. In such cases, your browser is trying to connect to a modern web server using old HTTP versions. So, the best way to fix this is to switch to a modern browser like Firefox or Google Chrome.

If you are using a modern browser and have faced error 505, then the quickest solution is to clear your browser’s cache. To work faster and consume less network traffic, most browsers employ caching methods, which store some features of the websites you visit. Sometimes, the cache and the actual website content don’t match up after a time and that can cause errors like 505 “HTTP version not supported.” As an example, we’ll tell you how to clear the cache in your Chrome browser.

Chrome offers different ways for managing and clearing the cache, but the quickest way is the following:

  • While in Chrome, press F12
  • Click on and hold the refresh button next to the address bar
  • From the menu that appears, select “Empty Cache and Hard Reload”

[Chrome Hard Reload Menu]

[Chrome Hard Reload Menu]

With that, you have managed to clear your browser’s cache. If the problem still refuses to go away, it is almost certainly a server-side issue, and there is not much you can do about it. If you have to visit an old website no matter what, you may consider emailing the administrator and asking telling them about the problem.

How to Resolve HTTP 505 Error: Server-Side Solutions

If you are running a WordPress-based website, or if you’re hosting a website using an old web server or hosting provider, you may be able to do something about error 505. 

Start Blogging
Start Blogging

Self-host your WordPress on top-tier hardware, featuring NVMe storage and minimal latency around the world — choose your favorite distro.

Get WordPress VPS

Checking the HTTP Version

The first step to solving the problem is to see which HTTP version your web server is actually using. To do that, you can use TelNet in Windows or the curl command in Linux. Since TelNet has plenty of instructions available online, we’ll cover the steps to checking the HTTP version using the Linux command line.

First, we need to start the Terminal. That can be done by pressing Ctrl+Alt+T in most distros and from the Applications menu in all of them. Once you have the Terminal open, enter the following command and press <Return>

curl --head http://example.site/

Of course, you need to change “example.site” with the address of your own website. When you execute this command, you should see a list of properties that will look something like this:

[Linux Terminal Request for HTTP Version]

[Linux Terminal Request for HTTP Version]

The very first line of the response will be in the following format: “HTTP/#” where # is the HTTP version used by the webserver. Here, the HTTP version for our website is displayed as 2. If this number is below 1.1, chances are modern browsers won’t be able to properly communicate with it. In that case, you should update your webserver to the latest version. If you’re using a web hosting control panel, like cPanel or Plesk, simply updating that will take care of everything.

When the problem shows up in WordPress, however, the reason is something else, and it will need a different solution. Let’s take a look.

WordPress Problem

Sometimes, WordPress plugins will try to connect to third-party websites on the route to some outgoing link and that can cause problems. Imagine, for example, that you want to direct your customer to your product sold on Amazon. You may use static URLs to your product that are completely okay but when someone clicks on them from your website, they’ll get the 505 error. That’s usually because of a plugin and the difference between the third-party website’s HTTP version and that of the real destination. To test that, you can use the above method using curl to check the HTTP version of your website and the one you’re linking to.

WordPress Solution #1

There are two ways you can deal with this. If you are using only a few plugins, we recommend you switch off the plugins one by one to find the culprit. You can then replace it with an alternative or code of your own. That’s not always a practical solution, however. You may have too many plugins to find the one responsible for the 505 error code, or you may be unable to part with it even if you do find the plugin. That’s why the following method may well be worth it, despite being only a workaround.

Start Blogging
Start Blogging

Self-host your WordPress on top-tier hardware, featuring NVMe storage and minimal latency around the world — choose your favorite distro.

Get WordPress VPS

WordPress Solution #2

This method involves disabling the WordPress Link Checker, which finds and reports broken links. Usually, it’s a useful tool that lets you remove unwanted and old links. When it starts reporting working links as broken because of plugins, it can potentially damage your website. The false reports on broken links can make a real analysis of your website impossible and a lot of seemingly broken links can lower your SEO ranking. To avoid all that, we need to switch off the Link Checker for the websites giving off a false alarm.

Once you find all the working links that still respond with a 505 error code, you can exclude them from the link checker using the following steps:

  • Go to your WordPress Dashboard
  • Go to Settings → Link Checker → Which Links to Check
  • Add the domain(s) to the Exclusion list
  • Click Save Changes

A Simpler Way?

And that’s that. That ought to have taken care of the 505 error code in all its manifestations. Of course, there’s always a chance that it won’t go away so simply. How to resolve HTTP 505 error then? Well, one simple way is to stop worrying about it and leave everything to us. Our optimized WordPress VPS running on top-tier infrastructure and using the latest software versions ensure you won’t run into this kind of error. You can leave updating and backups to us and devote your time to being more productive. Take a look at our WordPress VPS solutions here. 

Понравилась статья? Поделить с друзьями:
  • Ошибка 505 android
  • Ошибка 5041 терминал сбербанка
  • Ошибка 5040 терминал
  • Ошибка 5040 теле2
  • Ошибка 5040 гранта