An unexpected, $360 cloud bill

The Mistake

Late last month I wanted to do some analytics. I explored a couple of options, one of which was a Cloud SQL instance on Google Cloud.

I spun that up on November 28th, 2020, messed around with it for about an hour, and Mistake #1: I didn’t immediately shut it down.

I couple weeks later I got a notification that I was being billed a couple hundred dollars for Google Cloud. On any other day, this would have set off alarm bells and I would have panicked and looked into it. Unfortunately, the day before, I had decided to do a one-off heavy use of one of their APIs that I knew was going to incur costs. I had estimated it would cost me ~$20. When I was charged ~$200 instead, I was shocked and disappointed, but assumed that I was off by an order of magnitude and that I would need to be more careful estimating in the future. Mistake #2: Being too quick to assume that I had made an estimation mistake.

A few days ago I took another look at the billing information and was shocked to see that my cloud bill had almost doubled since I last got that notification. What the fuck? I looked at the breakdown and saw that it was a Cloud SQL charge. I immediately shut down the instance, feeling like an idiot.

Postgres Cloud SQL pricing advanced configuration

Support Ticket

I opened a support ticket with two goals:

  1. Learning why this mistake cost me so much money
  2. Maybe getting a refund

I’m happy to report that after complaining, asking for an escalation, complaining about the bad defaults and asking for a refund, I got refunded the full amount. Lesson: be the squeaky wheel.

First off, thank you, Google. I know you didn’t have to do that.

But I didn’t get an answer to my first question. They just gave me a bunch of copy pasted advice about making sure my database was secured. How did I incur $360 in 20 days?

Cost Breakdown

If you look at the hourly pricing you get these numbers:

Postgres Cloud SQL pricing

I found the culprit buried in the minimized “configuration options”:


Postgres Cloud SQL pricing

Configuration Options

Postgres Cloud SQL pricing advanced configuration

Cost Breakdown

  • Regional = HA (High availability)
  • 4 cores
  • 26 GB

20 days * 24 hours = 420 hours

4 cores * 720 hours = 1680 CPU hours.

1680 * .0826 = 138.77

26 * 420 = 10920 GB hours.

10920 * .140 = 152.88

152.88 + 138.77 ~= 300

So those numbers look about right.

Mistake #3: Not looking at the advanced configuration to see what hidden variables were lurking.

Mistake #4: Not doing a rough estimate of costs before spinning something up.


The default Postgres Cloud SQL instance is going to cost you ~450/month.

Feedback for Google

At the end of the day, I made a series of mistakes here and take full responsibility. That said, Google could do a better job of not letting people fall into this trap. Maybe make the default instance smaller? Or if most people want instances of this size (maybe it’s a sensible default?) then put a cost estimate when you’re creating the instance? Or move the instance size details out of the hidden section?

comments powered by Disqus