Photoionization (PI) of multiply and highly charged ions was studied using an electron beam ion trap and synchrotron radiation at the BESSY II electron storage ring. The versatile new method introduced here extends the range of ions accessible for PI investigations beyond current limitations by providing a dense target of ions in arbitrary, i. e., both low and high, charge states. Data on near-threshold PI of N 3+ and Ar 8+ ions, species of astrophysical and fundamental interest, show high resolution and accuracy allowing various theoretical models to be distinguished, and highlight shortcomings of available PI calculations. We compare our experimental data with our new fully relativistic PI calculations within a multiconfiguration Dirac-Fock approach and with other advanced calculations and find generally good agreement; however, detailed examination reveals significant deviations, especially at the threshold region of Ar 8+ .