Web pages are typically comprised of different kinds of visual elements such as menus, headers and footers. To improve user experience, eye tracking has been widely used to investigate how users interact with such elements. In particular, eye movement sequences, called scanpaths, have been analysed to understand the path that people follow in terms of these elements. However, individual scanpaths are typically complicated and they are related to specific users, and therefore any processing done with those scanpaths will be specific to individuals and will not be representative of multiple users. Therefore, those scanpaths should be clustered to provide a general direction followed by users. This direction will allow researchers to better understand user interactions with web pages, and then improve the design of the pages accordingly. Existing research tends to provide a very short scanpath which is not representative for understanding user behaviours. This thesis introduces a new algorithm for clustering scanpaths, called Scanpath Trend Analysis (STA). In contrast to existing research, in STA, if a particular element is not shared by all users but it gets at least the same attention as the fully shared elements, it is included in the resulting scanpath. Thus, this algorithm provides a richer understanding of how users interact with web pages. The STA algorithm was evaluated with a series of eye tracking studies where the web pages used were automatically segmented into their visual elements by using different approaches. The results show that the outputs of the STA algorithm are significantly more similar to the inputted scanpaths in comparison with the outputs of other existing work, and this is not limited to a particular segmentation approach. The effects of the number of users were also investigated on the STA algorithm as the number of users required for scanpath analysis has not been studied in depth in the literature. The results show the possibility to reach the same results with a smaller group of users. The research presented in this thesis should be of value to eye tracking researchers, to whom the STA algorithm has been made available to analyse scanpaths, and to behaviour analysis researchers, who can use the algorithm to understand user behaviours on web pages, and then design, develop and present the pages accordingly.