All Tools View Categories About Contact Privacy

KMS Key ARN Generator

Build a KMS key ARN by key ID or by alias.

For an alias, just type the name — the alias/ prefix is added for you. Runs entirely in your browser.
Fill in region, account id and a key id or alias to build an ARN.

About KMS Key ARN Generator

A KMS key can be referenced two different ways in an ARN — by its permanent key ID (a UUID assigned at creation) or by a friendly alias that points at a key and can be repointed later — and the two produce ARNs that look almost identical except for one word: key/ versus alias/. KMS Key ARN Generator builds either form from region, account id, a key-vs-alias toggle, and a value, with one specific guard rail: if you type the alias field with a leading alias/ that you copied from somewhere else, the tool strips it before reapplying the prefix exactly once, so you never end up with a doubled alias/alias/ segment.

Toggle to Key ID and the value field expects the key’s UUID — something like 1234abcd-12ab-34cd-56ef-1234567890ab — producing arn:aws:kms:region:account:key/1234abcd-.... This is the permanent, unambiguous reference to one specific KMS key; it never changes for the life of the key. Toggle to Alias and the value field expects just the alias name without any prefix — my-key-alias, not alias/my-key-alias — producing arn:aws:kms:region:account:alias/my-key-alias. Aliases exist precisely so you can reference a key by a stable, meaningful name in policies, application configuration, and CloudFormation templates while retaining the ability to repoint that name at a different underlying key later — for a key rotation strategy, or when promoting a freshly created key into production — without touching every place the alias is referenced.

The alias-prefix guard rail exists because it’s an extremely common copy-paste mistake: someone copies an alias value out of the KMS console or an existing ARN, where it already reads alias/my-key-alias, and pastes the whole thing into a field that’s only supposed to hold the name portion. Typed that way into a naive form, you’d get alias/alias/my-key-alias in the resulting ARN — subtly broken, and easy to miss on a quick read. This tool detects a leading alias/ in the value you typed, strips it, and reapplies the prefix exactly once, so the same input either way — my-key-alias or alias/my-key-alias — produces the identical, correct ARN.

Like every other regional AWS service in this tool family, KMS keys and aliases are scoped to a specific region and account, so both fields are required and checked at build time for a real-looking region code and a 12-digit account id. The key ID field itself isn’t validated against the UUID format, deliberately — you may be filling in a template placeholder or working from a key ID captured in a different context, and the tool would rather build the ARN than block on a format guess it can’t be fully sure about.

Once the required fields are filled, a live preview shows the ARN updating as you type. Clicking Build runs the result through the shared structural validator and reveals a one-click Copy button. A Load sample button fills in a realistic region, account, and alias so you can see the guard rail in action; Clear resets everything. As with every tool here, key IDs, aliases, and account ids never leave your browser.

Features

  • Four-field form — region, account id, key/alias toggle, value.
  • Key ID or alias ARN from the same form via a toggle.
  • Automatic alias-prefix guard — a value pasted with a leading alias/ is detected and normalized instead of doubling the prefix.
  • Supports AWS-managed key aliases like aws/s3.
  • Live preview that updates as you type.
  • Region and account format validation using the shared ARN validator.
  • Built on the shared buildARN engine, not a hand-rolled string template.
  • Sample region/account/alias preloaded with one click.
  • One-click copy and clear.
  • 100% client-side — key ids and aliases never leave the page.

How to Use

  1. Enter a region (e.g. us-east-1) and a 12-digit account id.
  2. Toggle Key ID or Alias.
  3. Type the key’s UUID, or just the alias name (with or without a leading alias/ — either works).
  4. Watch the live preview update as you fill in fields.
  5. Click Build to validate and reveal the copy action.
  6. Copy the ARN into your IAM policy, key policy, or encryption configuration.
  7. Clear and repeat for the next key or alias.

Examples

Example 1 — Key ID ARN. Region us-east-1, account 123456789012, type Key ID, value 1234abcd-12ab-34cd-56ef-1234567890ab, gives arn:aws:kms:us-east-1:123456789012:key/1234abcd-12ab-34cd-56ef-1234567890ab.

Example 2 — Alias ARN. Same region and account, type Alias, value my-key-alias, gives arn:aws:kms:us-east-1:123456789012:alias/my-key-alias.

Example 3 — Alias typed with the prefix already on it. Value alias/my-key-alias still produces the identical arn:aws:kms:us-east-1:123456789012:alias/my-key-alias, not a doubled prefix.

Example 4 — AWS-managed key alias. Type Alias, value aws/s3, gives arn:aws:kms:us-east-1:123456789012:alias/aws/s3, the alias for the AWS-managed key used for default S3 encryption.

Example 5 — Different region, same key alias. The same alias name deployed independently as region eu-west-1 produces a distinct ARN, since KMS keys and aliases are regional.

Benefits

  • Prevents the doubled alias/alias/ mistake automatically.
  • One form for both key ID and alias references.
  • Supports AWS-managed key aliases alongside customer-managed ones.
  • Catches malformed regions and account ids before they reach a policy document.
  • Consistent with the shared ARN engine used across this entire tool family.
  • Private — key ids, aliases and account ids never leave your browser.

Frequently Asked Questions

Should I type "alias/" myself in the alias field?
No — the tool adds the <code>alias/</code> prefix automatically. If you type it anyway (e.g. <code>alias/my-key-alias</code> instead of just <code>my-key-alias</code>), it’s detected and stripped before the prefix is reapplied once, so you still get the correct <code>arn:aws:kms:region:account:alias/my-key-alias</code> rather than a doubled prefix.
What’s the difference between a key ARN and an alias ARN?
A key ARN (<code>arn:aws:kms:region:account:key/1234abcd-...</code>) references the KMS key directly by its key ID, a UUID assigned when the key is created. An alias ARN (<code>arn:aws:kms:region:account:alias/my-key-alias</code>) references a friendly name that points at a key — the same underlying key can have multiple aliases, and which key an alias points to can be changed without updating anything that references the alias.
Why would I use an alias instead of the key ID directly?
Aliases let you rotate which physical key a name points to (for key rotation strategies, or promoting a newly created key) without updating every policy, application config, or CloudFormation template that references it by name. Key IDs are permanent and specific; aliases are the recommended way to reference a key when you want that flexibility.
Does the tool check the key ID looks like a real UUID?
It requires a non-empty value in the key ID field but does not enforce the UUID format — you may be working with a template placeholder or a key ID copied from a different context, so the check stays permissive here rather than blocking on format.
Why does KMS need both a region and an account id?
KMS keys are regional and scoped to one account — the same key ID or alias name could theoretically exist in different regions or accounts, so both are required to identify exactly one key.
Is my key ID or alias sent anywhere?
No. The ARN is assembled entirely in your browser with no network requests.
What does the validation step check?
It runs the finished ARN through the shared structural validator: partition, service name shape, 12-digit account id, and a real-looking region code. It does not verify the key or alias actually exists in KMS.
Can I build an ARN for an AWS-managed key alias like aws/s3?
Yes — type <code>aws/s3</code> (without the <code>alias/</code> prefix) into the alias field and the tool produces <code>arn:aws:kms:region:account:alias/aws/s3</code>, the correct ARN for that AWS-managed key’s alias.