Some connectors have versions that are higher, and occasionally you can find a through hole mount connector where you can use a spacer underneath to place it slightly higher.
If you are manufacturing many of these, talk to the connector manufacturer and see what they suggest. They can use the same connector with different pins that act like stilts and place the connector higher, or they can custom mold a connector for you - but the quantity has to be fairly high for the cost to be similar to the off the shelf connector.
Beyond that, your only option really is to use another PCB with a specific thickness. This would probably be less expensive than a custom connector if the quantity is small, and more expensive than a custom connector if the quantity is large.
For the connector-on-pcb mounting, use a PCB with castellations for heights under 3mm:
When you have a PCB made, you can tell the fabrication company how thick you want the PCB to be. They have a range of FR4 stock with varying thicknesses that can be laminated to provide a range of thicknesses. First, mount the connector on the PCB, then you can put the PCBs with connectors into a tray and have them machine placed.
For heights greater than 3mm, using headers would work well.
Honestly, though, I think you need to reconsider the problem. If you are trying to get a connector to line up with the outside of the case, you should be moving the PCB, or the case hole, or separating the two and using a panel mount connector.
The problem with raising the connector is that when it's connected and disconnected, greater forces are placed on the connector and PCB, and the mount may not be strong enough to deal with those forces, particularly if it's frequently done.
If the connector needs to be raised, you should use a different connector that is meant to be further off the PCB. Trying to use a surface mount, fine pitch connector on a riser is just asking for trouble.