How does Shopify host private applications and where do they run?

I understand that regular apps can be hosted anywhere like AWS, DigitalOcean, or your own hosting. But I’m curious about private applications that are only accessible to a single store. Do these run on Shopify’s own infrastructure? Or do they work the same way as regular apps with external hosting? Also wondering - if private apps do get hosted by Shopify directly, is there any way to get a public app hosted on their servers as well?

Any insights would be helpful!

People often think Shopify hosts private apps, but that’s not true. When you create a private app in your Shopify admin, you’re just getting API credentials so your custom code can talk to that store’s data. Your actual code runs on your own server, cloud hosting, or even your local machine. The main difference between private and public apps isn’t hosting - it’s distribution. Private apps only work for one store, while public apps go through Shopify’s review process to reach everyone. Either way, Shopify doesn’t host your code. They just provide the platform and API support.