Embodiments of the present invention provide a method, device, and computer-readable storage medium for accessing a server. In the embodiment of the present invention, the first server obtains the IP address and the session identifier of the second server providing the transfer service, and uses the private key of the first server to pair the block chain identifier, the domain name, and the IP address of the second server with the first server. The address and the session identifier are signed to obtain the signed domain name registration information, and further, the signed domain name registration information is broadcast to the domain name block chain, so that the block chain nodes that need to access the first server pass through the The second server accesses the first server, so that the IP address and port number of the first server are hidden from the public network, preventing the first server from being attacked by other devices in the public network, thereby improving the performance of the first server. A server's security.