How to prevent accidental costs using the Azure free account

Bones 0 Reputation points
2024-07-08T14:59:04.4266667+00:00

I am using the Azure free account and my 30 days has expired requiring me to upgrade to Pay as you Go. However I do not want to incur any costs, is there a way to limit my use to only the free resources while I learn Azure?

Thanks

Azure Cost Management
Azure Cost Management
A Microsoft offering that enables tracking of cloud usage and expenditures for Azure and other cloud providers.
2,494 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Andreas Baumgarten 107.7K Reputation points MVP
    2024-07-08T15:30:50.99+00:00

    Hi @Bones ,

    the only option I know so far is to implement a an Azure Policy that only allows to deploy free services.

    For instance allow to deploy a B1s VMs, deny all other VM SKUs.

    The main issue I can see with this solution: You might not be able to prevent the deployment of multiple B1s VMs, but only 750 hours of B1s VM is free (as far as I am aware of).

    The code might look like this (not tested):

    {
        "if": {
            "allOf": [
                {
                    "field": "type",
                    "in": [
                        "Microsoft.Compute/virtualMachines"
                    ]
                },
                {
                    "field": "Microsoft.Compute/virtualMachines/sku.name",
                    "in": ["Standard_B1s"],
    				"in": ["Standard_B2pts_v2"],
    				"in": ["Standard_B2ats_v2"]
                },
    			]
        },
        "then": {
            "effect": "deny"
        }
    }
    
    

    You can add Policy rule sets for storage accounts and other services the same way.


    (If the reply was helpful please don't forget to upvote and/or accept as answer, thank you)

    Regards

    Andreas Baumgarten

    0 comments No comments

  2. VarunTha 7,635 Reputation points Microsoft Vendor
    2024-07-08T16:07:51.1633333+00:00

    Hi Bones,

    For focused and dedicated assistance with this issue, please file a subscription ticket with our support team. You can submit a (free) support ticket with our Azure subscription support team by creating an Azure support request and selecting Subscription Management as the issue type.

    Refer to this FAQ: How do I submit a support request if I can't sign in to the Azure portal?

    You can also contact customer service for your country or region. Please don't forget to Accept helpful answer and close this thread. Thank you.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.