SUMMARYGraphical user interfaces are not always developed for remaining static. There are GUIs with the need of implementing some variability mechanisms. Component-based GUIs are an ideal target for incorporating this kind of operations, because they can adapt their functionality at run-time when their structure is updated by adding or removing components or by modifying the relationships between them. Mashup user interfaces are a good example of this type of GUI, and they allow to combine services through the assembly of graphical components. We intend to adapt component-based user interfaces for obtaining smart user interfaces. With this goal, our proposal attempts to adapt abstract component-based architectures by using model transformation. Our aim is to generate at run-time a dynamic model transformation, because the rules describing their behavior are not pre-set but are selected from a repository depending on the context. The proposal describes an adaptation schema based on model transformation providing a solution to this dynamic transformation. Context information is processed to select at run-time a rule subset from a repository. Selected rules are used to generate, through a higher-order transformation, the dynamic model transformation. This approach has been tested through a case study which applies different repositories to the same architecture and context. Moreover, a web tool has been developed for validation and demonstration of its applicability. The novelty of our proposal arises from the adaptation schema that creates a non pre-set transformation, which enables the dynamic adaptation of component-based architectures.