In this article an optimal control scheme is proposed to solve robust control problem for matched and unmatched system. In the proposed optimal approach the value functions are designed such that the obtained optimal control law guarantees asymptotic stability of the uncertain nonlinear system. Since the proposed robust optimal control problem is not straightforward to solve, an off‐policy reinforcement‐learning algorithm based on neural networks approximation is developed to obtain robust optimal control law iteratively. The robust control law for matched uncertain systems can be achieved via proposed off‐policy learning algorithm without requiring exact knowledge of system's dynamics. The advantages of the proposed robust optimal controller are verified by comparative simulations on an uncertain model of a car suspension system and a mathematical nonlinear model.