The Neutral Gas and Ion Mass Spectrometer of the Mars Atmosphere and Volatile Evolution provides a large data set to explore the ion composition and structure of the Martian ionosphere. Here, the dayside measurements are used to investigate the minor ion density profiles with distinctive peaks above 150 km, revealing a systematic trend of decreasing peak altitude with increasing ion mass. We specifically focus on a subset of species including O+, N
2+/CO+, C+, N+, He+, and O++, all of which are mainly produced via direct photoionization of parent neutrals. Our analysis reveals weak or no variation with solar zenith angle (SZA) in both peak density and altitude, which is an expected result because these ion peaks are located within the optically thin regions subject to the same level of solar irradiance independent of SZA. In contrast, the solar cycle variations of peak density and altitude increase considerably with increasing solar activity, as a result of enhanced photoionization frequency and atmospheric expansion at high solar activities. He+ serves as an exception in that its peak density increases toward large SZA and meanwhile shows no systematic variation with solar activity. The thermospheric He distribution on Mars should play an important role in determining these observed variations. Finally, the peak altitudes for all species are elevated by at least several km within the weakly magnetized regions, possibly attributable to the suppression of vertical diffusion by preferentially horizontal magnetic fields in these regions.