This paper proposes a genetic algorithm for solving a unit commitment problem of electric generators, which formally is a mixed integer nonlinear programming problem. The proposed algorithm finds the optimal ON/OFF status of units by a combination of genetic algorithm and continuous relaxation method. In the proposed algorithm, a chromosome encodes a partial solution, in which the values of some variables are unfixed. The fitness of an individual is evaluated based upon a solution of the problem where all unfixed variables in the chromosome are relaxed to be continuous. Numerical experiments show the satisfactory performance of the proposed algorithm with respect to the solution quality for planning the actual unit commitment schedule.