**
Introduction
Ethereum blockchain and its associated APIS, including the API Binance website. The
The problem
HTTPS Connection to ensure that the data is properly authenticated and validated. The Default Websocket URL wss: //stream.binance.com: 9443
Uses the Safety Encryption of the Transport Layer (TLS), which encrypts To another final point.
The Solution
TLS Redirect. Here’s How to Change Your Code:
`JavaScript
Import io from "socket.io-clien";
Const socket = Io ('
// or for FTP (File Transfer Protocol)
Const ftpurl = 'ftp://stream.binance.com:9443';
Socket.on ('connect', () => {
Console.log ("Connected to Binance Websockets API");
});
` ‘
Modified Code Test
Try to run your modified code in a chrome browser and check that you can successionfully connect to the binance website websockets api. If you always encounter problems, make sure that:
- You have installed the latest version of chrome.
2.
Conclusion
Http or FTP, you should sucket connection with Binance Exchange without encountering the https redirection problem in chrome and firefox browsers.