In this paper, a quadratic stabilizing controller minimizing a cost function is designed through model-free and online reinforcement learning for systems with logarithmic quantized input. By introducing a new gain dependent on quantization density, the input and related weighting matrix in the cost function are deviated from their original ones. Then, using these deviated parameters, the controller is trained through reinforcement learning such that the closed-loop system satisfies the quadratic stability condition with the cost function minimized. An inverted pendulum example is used to show the effectiveness and merits of the proposed method.