The cellular automata (CA) approach to traffic modelling is extended to allow for spatially homogeneous steady state solutions that cover a two-dimensional region in the flow–density plane. Hence these models fulfil a basic postulate of a three-phase traffic theory proposed by Kerner. This is achieved by a synchronization distance, within which a vehicle always tries to adjust its speed to that of the vehicle in front. In the CA models presented, the modelling of the free and safe speeds, the slow-to-start rules as well as some contributions to noise are based on the ideas of the Nagel–Schreckenberg-type modelling. It is shown that the proposed CA models can be very transparent and still reproduce the two main types of congested patterns (the general pattern and the synchronized flow pattern) as well as their dependence on the flows near an on-ramp, in qualitative agreement with the recently developed continuum version of the three-phase traffic theory (Kerner B S and Klenov S L 2002 J. Phys. A: Math. Gen. 35 L31 ). These features are qualitatively different from those in previously considered CA traffic models. The probability of the breakdown phenomenon (i.e. of the phase transition from free flow to synchronized flow) as function of the flow rate to the on-ramp and of the flow rate on the road upstream of the on-ramp is investigated. The capacity drops at the on-ramp which occur due to the formation of different congested patterns are calculated.