This paper addresses the data-based networked control problem for a class of nonlinear systems. Network communication constraints, such as network-induced delay, packet disorder, and packet dropout in both the feedback and forward channels, are considered and further treated as the round-trip time (RTT) delay that is redefined. By using the packet-based transmission mechanism and the model-free adaptive control algorithm, a data-based networked predictive control method is proposed to actively compensate for the random RTT delay. The proposed method does not require any information on the plant model and depends only on the input and output data of the plant. A simple and explicit sufficient condition, which is related to the upper bound of the RTT delays, is derived for the stability of the closed-loop system. Additionally, a zero steady-state output tracking error can be achieved for a step reference input. The effectiveness of the proposed method is demonstrated via simulation and experimental results.