Class diagrams in UML can show various relationships between classes including generalization, association, aggregation, composition, and dependency. Generalization specifies inheritance between a base class and derived class. Association defines a relationship between two classes without ownership. Aggregation represents a whole-part relationship where the part can exist without the whole. Composition is a stronger form of aggregation where the part cannot exist without the whole. Dependency specifies that a change to one class may affect another class.