We analyze the optimal licensing strategy of an outside patent holder of a superior quality technology for a Bertrand duopoly with different product quality in a finite stage sequential bargaining game. Two types of fixed-fees are considered, a strategic one and the conventional one. If the new technology is owned by a revenue maximizing outsider, it is shown that the optimal licensing strategy is transferring the patent (1) to the original high quality firm with a strategic fixed fee when the quality difference between the duopoly is large enough, (2) to the original high quality firm with a conventional fixed fee when the quality difference is small and the new technology helps little, and (3) to the original low quality firm with a conventional fixed fee, otherwise. If the new technology is owned by a social welfare maximizing government agency, it is shown that transferring technology to the low quality firm is optimal and a subsidy is required in case the new quality is improved very little.