Molecular mechanics techniques using a modified version of the program MM2(87) were used to analyze the ruffling of metalloporphyrins as a function of metal ion size, orientation of axial ligands, and orientation of substituents on the porphyrin periphery. The structures chosen for the parametrization, [P(TPP)(OH)2]+, the planar and ruffled forms of low-spin (S = 0) [Ni(OEP)], (S = 1) [Fe(TPP)], [Zn(TPP)], and [Pb(TPrP)], contain metal ions of very different sizes and hence extents of porphyrin core ruffling. The planar and moderately ruffled structures could be satisfactorily reproduced by developing new parameters involving the metal ion and using the parameters built into the program for the porphyrin core. The total strain energy in a planar metalloporphyrin was investigated as a function of metal ion size. The principal components which contribute to the total strain energy are nonbonded van der Waals repulsion, bond angle deformation, and bond length deformation. A minimum in the strain energy curve occurs at 2.035 angstrom which is the best-fit metal ion size in the planar macrocycle cavity. In the case of the very small ion, P(V), only a ruffled conformer is possible, but for intermediate size metal ions (Ni(II) and Fe(II)) both planar and ruffled forms of the metalloporphyrins were found (in accord with the experimental observation of the two forms of [Ni(OEP)] in solution and in the solid state), As ruffling increases, there is a balance between a decrease in bond length deformation and angle bending strain, and an increase in torsional strain, such that the energy difference between the two forms is small with the planar structure 1-1.5 kcal.mol-1 more stable. For the larger ion, Zn(II), only the planar form was found, and for the very large ion, Pb(II), a domed structure results in which the coordination geometry is best described as square pyramidal. The flexibility of the porphyrin core was further demonstrated by showing that at the expense of a modest 1.3 kcal.mol-1 (arising principally from an increase in angle bending strain) the porphyrin ring can undergo a cavity expansion of 0.15 angstrom and accommodate a change in the spin state of Fe(II) from low spin to high spin without requiring the metal ion to be extruded out of the mean plane. The ruffling of a metalloporphyrin is normally either of the sad or ruf variety, and the sense and extent of the ruffling is demonstrated to be controlled by the specific orientations of phenyl groups in TPP complexes and by the orientation of ligands such as 2-methylimidazole coordinated to the axial sites of the metal ion. Some examples of the ruffling of porphyrins in hemoproteins in response to their environment are considered.