What retires on 31 January, and what Azure names as the replacement
Microsoft's retirement schedule lists four deployments for 2027-01-31: grok-4 and grok-code-fast-1 under xAI, and Llama-3.3-70B-Instruct and Llama-4-Scout-17B-16E-Instruct under Meta. The Replacement column is empty for all four.1 Llama-3.3-70B-Instruct appears twice, once under the models Azure sells directly and once under partners and community, with the same date. Scout appears only in the partner list. If you deployed either from more than one place, inventory both.
An empty replacement column matters because automatic upgrades follow it. Microsoft says the listed replacement is the recommended migration target and, where supported, the target for automatic upgrades, and that it declares the replacement about 90–120 days before retirement.2 For 31 January that window opened in early October, and the page I read (updated 2026-09-23) still had nothing in it. Re-read it, but do not plan around an upgrade arriving. After retirement, inference returns 410 Gone.2
Two dates to put in the calendar now. GA retirement notices go to subscription owners at least 60 days before retirement, which for this date is about 2 December.2 And Llama-4-Maverick-17B-128E-Instruct-FP8 retires on 2026-11-19, tomorrow, so if Maverick shares a code path with Scout, fix both at once.1
The mapping: each retiring deployment to two targets
The same-cloud column uses only ids that appear in the same schedule. The cross-provider column names a direct vendor route you would call from outside Azure. Neither is a recommendation of quality; both need your own test set.
| Retiring on 2027-01-31 | Same-cloud (Foundry) candidate | Cross-provider candidate | First thing to check |
|---|---|---|---|
| grok-4 | grok-4-1-fast-reasoning (retires 2027-05-19) | xAI API, grok-4.7 | Reasoning behaviour and output length on your prompts |
| grok-code-fast-1 | grok-4-1-fast-non-reasoning or -reasoning (both 2027-05-19) | xAI API, grok-4.7 or grok-build-0.1 | Tool-call and diff formatting in your agent loop |
| Llama-3.3-70B-Instruct | gpt-oss-120b (retires 2027-09-15) or DeepSeek-V4-Flash (2028-02-20) | The same open-weight model on another host, or a DeepSeek direct route | Prompt template and context length |
| Llama-4-Scout-17B-16E-Instruct | The same two, or mistral-small-4-119b-2603 | As above | Image input, if you send images |
The schedule shows gpt-oss-120b and DeepSeek-V4-Flash as GA, and names mistral-small-4-119b-2603 as the replacement for mistral-small-2503.1 I did not read any page that compares these with Llama on quality, so treat them as candidates to test, not equivalents.
Grok: same-cloud targets buy months, not years
The schedule has a precedent. When grok-4-fast-reasoning and grok-4-fast-non-reasoning retired on 2026-05-01, the named replacements were grok-4-1-fast-reasoning and grok-4-1-fast-non-reasoning.1 Those two are the natural next step on Foundry, and they split reasoning and non-reasoning into separate ids. That split is a decision for you: grok-code-fast-1 traffic that never depended on reasoning maps to the non-reasoning id, and moving it to the reasoning id changes both latency and the tokens you pay for.
The catch is that both 4-1-fast ids are scheduled to retire on 2027-05-19, under four months after the date you are migrating for.1 The grok-4-20-* ids are Preview with a 2027-04-06 date, and Microsoft's policy says preview models are not recommended for production and are force-upgraded or terminated.2 If you take a 4-1-fast id as a bridge, put the May date on the same ticket.
The longer-lived option may be a newer Grok. Microsoft's policy says GA Grok models starting with Grok 4.7 are available for a minimum of six months.2 I did not find grok-4.7 in the Foundry schedule, and xAI's Foundry guide uses grok-4.3 as its example deployment.3 Check your own catalog before assuming either.
Direct from xAI, grok-4.7 is listed at a 500k context, with configurable reasoning.4 xAI's API page also lists Azure AI Foundry, OCI and Vertex Model Garden as other places Grok is offered.5
Llama: three routes, and one of them keeps the weights
For Llama, Foundry has no named successor, so the choice is a product decision. Three routes:
- A different model on Foundry. Candidates above. Foundry's lifecycle differs by publisher: GA models from Anthropic, DeepSeek, Fireworks and Mistral AI follow a 12-month lifecycle instead of the standard 18 months.2
DeepSeek-V4-Flashstill shows a 2028 date in the schedule, but a 12-month clock means you should expect another move inside a year or so. - Keep Llama on dedicated compute. Azure describes Managed Compute as dedicated GPU infrastructure for open-source and custom models, on A100, H100, H200 and MI300 GPU families.6 Microsoft already points Phi-4 customers there.1 I could not confirm that Llama 3.3 or Scout is offered on it; check the catalog, and read the Phi-4 piece for the cost shape of paying for GPUs by the hour.
- A different host or vendor. Because Llama weights are open, another host may serve the same family. Hosts differ in quantization and chat templates, which is the point of a same-weights, different-host consistency test.
Checklist: ids and API surface
On Foundry, the deployment name you choose is the value your code passes as model, and xAI's guide says the name cannot be changed after creation.3 So model="grok-4" in your code is a deployment name you created, not a catalog id, and a new target means a new deployment and a config change. Direct vendor ids are different strings.
- List every deployment name that points at the four retiring models, per subscription, region and deployment type. Provisioned deployments are not auto-upgraded in any case.2
- Grep code, config, notebooks and agent definitions for those names, and for the endpoint form
https://{resource}.services.ai.azure.com/api/projects/{project}/openai/v1.3 - Decide whether the new id is a deployment name (Foundry) or a vendor id (direct), and keep one mapping table instead of literals in code.
- Pin dated ids where the vendor offers them. xAI's docs describe aliases that follow the latest stable version or the latest version, which move under you.4
- Re-test request fields. xAI says
logprobsandtop_logprobsare not supported by grok-4.20 and newer and are silently ignored.4 Silent is the risky word; assert on it. - Re-test reasoning controls.
grok-4.7has configurable reasoning, and on the Responses API it always returnsreasoning.encrypted_content.4 If you store or forward responses, that is a new field. - Check which API shape you call. xAI's docs list Chat Completions under legacy and a guide for moving to the Responses API, while the quickstart still shows chat completions at
https://api.x.ai/v1.45 - Treat 410 as non-retryable in clients and in any fallback list.2
Checklist: quota and capacity
Quota does not move with a deployment. A new Foundry deployment has its own limits, and a direct xAI account has its own. I did not read Foundry's quota page, so I give no TPM figures; read the quota for the new model and deployment type in your region.
- Record peak requests per minute and peak tokens per minute on each retiring deployment over a busy week. Size the new deployment to the peak, not the mean.
- Request quota on the target now, not in January. Deployment types roll out in an order: Global Standard first, with Data Zone and regional types later.2
- If you use Data Zone or regional deployments for data location, confirm the target exists in that zone. Microsoft notes that successive model versions might not be available in the same regions.2
- For direct xAI, note that limits increase automatically with usage on the self-serve path, and custom rate limits, invoicing, SSO and data residency are listed under the enterprise path.5 Ask for them before launch, not during an incident.
- Re-check timeouts. A reasoning-heavy target will have a different time to first token than
grok-code-fast-1.
Checklist: pricing and billing path
Foundry Grok models are billed through your Azure subscription.3 Models sold by Azure are described as billed through the subscription and covered by Azure service-level agreements.7 Moving to xAI directly changes the billing relationship, the contract and possibly how the spend counts against any cloud commitment; the commit question is worth asking your account team before you move volume.
Rates are where the existing tables stop. Azure's Grok pricing page is filtered by region and currency and says prices are estimates that may vary with your agreement.6 The direct xAI list I read covers grok-4.7, grok-build-0.1, grok-4.6, grok-4.5, grok-4.3 and the 4.20 family, and includes neither grok-4 nor grok-code-fast-1 nor the 4-1-fast ids.8 There is no like-for-like vendor baseline, so use your own Azure cost per deployment as the "before".
What the direct list does show:
grok-4.7: $2.00 input, $0.50 cached input and $6.00 output per million tokens for short context, and $4.00, $1.00 and $12.00 for long context, which starts at 200k tokens.8- Long-context rates apply to all tokens in a request once the prompt reaches the threshold, not only the excess.8
- Requests sent to the US regional endpoint are billed at 1.1x the global rates.8
grok-build-0.1lists a 256k context at $1.00 input and $2.00 output, with the same 200k long-context threshold.8- Server-side tools add invocation charges on top of tokens.8 If your agent uses search or code execution, that is a new line item.
Different tokenizers also change the count for the same text, which moves the bill without any rate change; the tokenizer piece shows how to measure it.
Governance differences when you leave Azure
Foundry gives you Entra ID RBAC, optional private networking and Azure content-safety layers.3 A direct xAI account is a separate vendor with its own terms. Its API page lists SOC 2 Type II, a HIPAA BAA, data residency options and a Zero Data Retention setting for admins.5 Those are the vendor's statements; get the documents from the vendor and have your security reviewer read the data processing terms before any production prompt goes there.
Cutover: canary, compare, then retire the old deployment
Run the old deployment and the target side by side on real prompts. Keep the mapping outside application logic so the split is a config change.
import os, random
from openai import OpenAI
TARGETS = {
# label: (base_url, key_env, model_or_deployment_name)
"old": (os.environ["FOUNDRY_BASE_URL"], "FOUNDRY_KEY", "grok-4"),
"new": ("https://api.x.ai/v1", "XAI_API_KEY", "grok-4.7"),
}
SHARE_NEW = float(os.getenv("SHARE_NEW", "0.05"))
def call(messages):
label = "new" if random.random() < SHARE_NEW else "old"
base, key_env, model = TARGETS[label]
client = OpenAI(base_url=base, api_key=os.environ[key_env])
r = client.chat.completions.create(model=model, messages=messages)
return label, r # log label, latency, tokens, finish_reasonLog the label, latency, token counts and finish reason on every call, then compare error rate, truncation by length limit and output shape per label. Raise the share in steps, and keep the old deployment live until the new path has carried a full business cycle, including your peak. Mind the deadline: the old deployment stops working on the retirement date whatever your share is.
Where a gateway helps
A gateway can hold the split and the fallback so the application does not. INFRO's fallbacks array takes up to five catalog model ids and tries them in order, but only before the first token; connection failover across your own connections is same-model.9 Its model ids are vendor/model-name, and its docs say Azure runs its own retirement schedule, which INFRO covers only when that date is recorded.10 So do not rely on it to know Azure's January dates; keep your own calendar. Its experiments run a dataset across up to six variants with an estimated cost shown first, which fits comparing two candidates on logged prompts. Check the providers page for what your Foundry deployments connect as before planning around it.
Order of work to 31 January
- This week: inventory deployments and callers, and fix Maverick if it shares a path.
- By early December: pick one same-cloud and one cross-provider candidate per workload, request quota, and capture a baseline from your own Azure invoice.
- December: run the canary on real prompts and compare on your own scoring.
- Early January: move the majority share, and decide whether any 4-1-fast bridge needs a May follow-up.
- Before 31 January: remove the old names from code and config, and delete the old deployments once traffic is zero.
