Skip to content
Docs

vercel dns

The vercel dns command manages DNS records for domains: list, inspect, add, update, remove, and import records.

When adding DNS records, please wait up to 24 hours for new records to propagate.

terminal
vercel dns list

Using the vercel dns command to list all DNS records under the current scope.

terminal
vercel dns list [domain]

Using the vercel dns command to list the DNS records of a single domain.

terminal
vercel dns add [domain] [subdomain] [A || AAAA || ALIAS || CNAME || TXT] [value]

Using the vercel dns command to add an A record for a subdomain.

terminal
vercel dns add [domain] '@' MX [record-value] [priority]

Using the vercel dns command to add an MX record for a domain.

terminal
vercel dns add [domain] [name] SRV [priority] [weight] [port] [target]

Using the vercel dns command to add an SRV record for a domain.

terminal
vercel dns add [domain] [name] CAA '[flags] [tag] "[value]"'

Using the vercel dns command to add a CAA record for a domain.

terminal
vercel dns update [record-id] --name [name] --type [type] --value [value] --ttl [seconds]

Using the vercel dns command to update fields of an existing DNS record in place, using its ID.

terminal
vercel dns update [record-id] --mx-priority [priority]

Using the vercel dns command to update the priority of an MX record.

terminal
vercel dns update [record-id] --srv-priority [priority] --srv-weight [weight] --srv-port [port] --srv-target [target]

Using the vercel dns command to update an SRV record. All four --srv- options must be provided together.

terminal
vercel dns update [record-id] --comment "[comment]"

Using the vercel dns command to update the comment that describes what a DNS record is for.

terminal
vercel dns inspect [record-id]

Using the vercel dns command to show a single DNS record in full using its ID.

terminal
vercel dns remove [record-id]

Using the vercel dns command to remove a record for a domain.

terminal
vercel dns import [domain] [path-to-zonefile]

Using the vercel dns command to import a zonefile for a domain.

These are options that only apply to the vercel dns command.

The --limit option can be used to specify the maximum number of DNS records returned when using list with a domain argument. The default value is 20 and the maximum is 100.

terminal
vercel dns list example.com --limit 100

Using the vercel dns list command with the --limit option.

Use the --next option with list to show the next page of results. When there are more results, the command prints the cursor to pass:

terminal
vercel dns list example.com --next 1584722256178

Using the vercel dns list command with the --next option.

Use the --name option with update to set a new name for the DNS record. Using '@' as the name refers to the domain itself.

terminal
vercel dns update rec_1a2b3c4d5e6f --name api

Using the vercel dns update command with the --name option.

Use the --type option with update to set a new type for the DNS record. Valid types are A, AAAA, ALIAS, CAA, CNAME, MX, SRV, and TXT.

terminal
vercel dns update rec_1a2b3c4d5e6f --type CNAME

Using the vercel dns update command with the --type option.

Use the --value option with update to set a new value for the DNS record.

terminal
vercel dns update rec_1a2b3c4d5e6f --value 198.51.100.100

Using the vercel dns update command with the --value option.

Use the --ttl option with update to set a new Time to Live (TTL) for the DNS record, in seconds.

terminal
vercel dns update rec_1a2b3c4d5e6f --ttl 300

Using the vercel dns update command with the --ttl option.

Use the --mx-priority option with update to set a new priority for an MX record.

terminal
vercel dns update rec_1a2b3c4d5e6f --mx-priority 10

Using the vercel dns update command with the --mx-priority option.

Use the --srv-priority, --srv-weight, --srv-port, and --srv-target options with update to set new values for an SRV record. All four options must be provided together.

terminal
vercel dns update rec_1a2b3c4d5e6f --srv-priority 10 --srv-weight 0 --srv-port 389 --srv-target example.com

Using the vercel dns update command with the --srv-priority, --srv-weight, --srv-port, and --srv-target options.

Use the --comment option with update to add context on what the DNS record is for.

terminal
vercel dns update rec_1a2b3c4d5e6f --comment "used for the marketing site"

Using the vercel dns update command with the --comment option.

The remove subcommand asks you to confirm before it removes a record. Use the --yes option to skip the prompt, for example in a script:

terminal
vercel dns remove rec_1a2b3c4d5e6f --yes

Using the vercel dns remove command with the --yes option.

The update subcommand also asks you to confirm the change. It has no option that skips the prompt, so run it in an interactive terminal.

Use the --json option with list or inspect to output the result as JSON:

terminal
vercel dns inspect rec_1a2b3c4d5e6f --json

Using the vercel dns inspect command with the --json option.

The following global options can be passed when using the vercel dns command:

For more information on global options and their usage, refer to the options section.

Last updated August 21, 2026

Was this helpful?

supported.