Pimsner introduced theC*-algebra OXgenerated by a Hilbert bimoduleXover aC*-algebra A. We look for additional conditions thatXshould satisfy in order to study the simplicity and, more generally, the ideal structure of OXwhenXis finite projective. We introduce two conditions, “(I)-freeness” and “(II)-freeness,” stronger than the former, in analogy with J. Cuntz and W. Krieger (Invent. Math.56, 1980, 251–268) and J. Cuntz (Invent. Math.63, 1981, 25–40), respectively. (I)-freeness comprehends the case of the bimodules associated with an inclusion of simpleC*-algebras with finite index, real or pseudoreal bimodules with finite intrinsic dimension, and the case of “Cuntz–Krieger bimodules.” IfXsatisfies this condition theC*-algebra OXdoes not depend on the choice of the generators when A is faithfully represented. As a consequence, ifXis (I)-free and A isX-simple, then OXis simple. In the case of Cuntz–Krieger algebras OA,X-simplicity corresponds to the irreducibility of the matrixA. If A is simple and p.i. then OXis p.i.; if A is nonnuclear then OXis nonnuclear. Thus we provide many examples of (purely) infinite nonnuclear simpleC*-algebras. Furthermore ifXis (II)-free, we determine the ideal structure of OX.