Sequence alignment remains a fundamental tool in most tasks related to the prediction of protein sequence and structure. A C++ class library was developed to facilitate the rapid implementation of a variety of state-of-the-art pairwise sequence alignment techniques. These range from simple sequence to sequence to the advanced profile to profile alignments with optional secondary structure information. Suboptimal alignments, frequently used to estimate regions of confidence, can also be generated. The object oriented design facilitates rapid implementation, testing and extension of existing functionality. A simple web interface, which can also be useful in bioinformatics education, is also provided. Source code, online documentation and a prototypical web interface are freely accessible to academic users from the URL: http://protein.cribi.unipd.it/align/. A sample case study in the modelling of human Cytochrome P450 is discussed.