For iMac9,1, officially . . . El Capitan OS 10.11.

[Unofficially with a third party patcher: Sierra OS 10.12. But OS 10.7 or later must already be running on iMac.]

I suggest staying with the official Apple recommendations and only upgrade to OS 10.11. However, if you are an adventurous soul, create a clone of the partition with OS 10.11 on it, then use the App Store app and see if Sierra will download and install on your iMac.

[After Snow Leopard, all subsequent OS upgrades must be downloaded and installed through the App Store app which is on all Macs with OS 10.6.8 or later. But you can go direct from OS 10.6.8 to OS 10.11.]