Industrial robots are usually programmed to follow desired trajectories, and are very good at position-controlled tasks. New applications, however, often require physical contact between the robot and its environment, and then the position control accuracy is generally not sufficient. Force control is a suitable alternative. The environment is often stiff, and then it is crucial to design appropriate force controllers, which is non-trivial for a robot programmer. This paper presents an adaptive algorithm for choosing force control parameters, based on identification of a contact model. The algorithm is experimentally verified in an assembly task with an industrial robot.