A generalization of the binary tree and the Trie, called the hybrid tree, is defined in which a node can correspond to a key, to any substring in a key, or to a character of the alphabet from which the keys are formed. An algorithm is given for constructing an optimal hybrid tree and it is shown that the search time of an optimal hybrid tree is never larger than the search time of the Trie or the optimal binary tree representing the same set of keys.