Autoscale billing

Does autoscale charge on a per second basis?

e.g a 512mb instance costs 0.0000013 per second so for 20,000 reqs each of which take 60 seconds,
the formula would be = 0.0000013*(20,000*60) = $1.56?

It’s free to enable auto-scaling, but how much you are charged for usage is not per request but per-vm running. It’s not like serverless providers that charge per-request.

You would technically be correct if 20,000 requests were exactly sequential, but that’s quite unlikely. Realistically there are going to be some in parallel/concurrent.

The base cost of a small 256b vm is $1.94/mo (you get a free allowance but let’s ignore that). And so let’s say you had two vms. And both ran 24/7, for a month, that would be … $1.94x2. Whether they are idle the whole time, or maxed out the whole time. So if you got 1000 requests, or 10,000 or 100,000,000 requests … still, $1.94x2.

That’s for a whole month. Iff your anticipated 20,000 requests are all going to happen on one day, well of course you wouldn’t need them for the whole month. It’s based on the time the vm is running for.

Of course the bigger the load, the more vms you are likely to need. But that depends on your app, its CPU/memory needs etc. And any bandwidth/IPs etc cost on top.