Create a Server with Vultr

Vultr is a US-based company that has a great reputation for performance and value. They have a wide range of data centers around the world and a great API for automation.

Create an account

The first step is to create an account with Vultr. You can do this by going to their website and clicking the "Sign Up" button. With the link below, they offer $100 in credits. This is an affiliate link, meaning we get a small kickback if you sign up, but this doesn't affect our recommendations.

Sign Up with Vultr →

Create an API token

To create an API token, you'll need to sign in to the Vultr Console. Click on your name in the upper right, then click "API".

Go to Vultr API

On the API page, click the "Enable API" button.

Enable Vultr API

You'll see your API token on the page. Press the "Copy" button to copy the token to your clipboard.

Vultr API Token

Place the token in your .spin.yml file

In your .spin.yml file, you'll find a providers section where you can add your Vultr API token.

.spin.yml configure providers

##############################################################
# 👇 Providers - You must set at least one provider
##############################################################

providers:
  - name: vultr
    api_token: abc123def456ghi789jkl012mno345pqr678stu901vwx234yz

Set as VULTR_API_KEY environment variable

If you prefer to set the token as an environment variable, you can also set the VULTR_API_KEY variable in your .env file, secrets manager, or wherever you store your environment variables.

Configure users

Make sure you configure your system users in your .spin.yml file.

Learn more about users →

Example users configuration in .spin.yml

##############################################################
# 👇 Users - You must set at least one user
##############################################################

users:
  - username: alice
    name: Alice Smith
    groups: ['sudo']
    authorized_keys:
      - public_key: "ssh-ed25519 AAAAC3NzaC1lmyfakeublickeyMVIzwQXBzxxD9b8Erd1FKVvu alice"

Configuring a Vultr hardware profile

By default we set you up with a very cost-effective hardware profile to get up and running quickly.

.spin.yml default Hardware Profiles

##############################################################
# 🤖 Hardware Profiles
##############################################################

hardware_profiles:
  # Vultr
  - name: vultr_1c_1gb_ubuntu2404
    provider: vultr
    profile_config:
      region: ord
      plan: vc2-1c-1gb
      os: "Ubuntu 24.04 LTS x64"
      backups: true

You can uncomment the defaults we give you or create/modify your own hardware profile.

Profile ConfigDescriptionAPI Reference
regionThe data center and location you want to deploy your server to (pick the closest one to your customers).See below for common examples.
planThe type of server.See below for common examples.
osThe image to use for the server.Vultr Images
backupsWhether to enable snapshot backups for the server (may add 20% to the monthly price).Learn more about Vultr snapshot backups.

Common Region Values

The region value is the id of the region. You can find the full list of regions using the Vultr API.

LocationCountryValue
AmsterdamNetherlandsams
AtlantaUSAatl
BangaloreIndiablr
ChicagoUSAord
DallasUSAdfw
FrankfurtGermanyfra
LondonUKlhr
Los AngelesUSAlax
MumbaiIndiabom
New JerseyUSAewr
ParisFrancecdg
SeoulSouth Koreaicn
SingaporeSingaporesgp
SydneyAustraliasyd
TokyoJapannrt
TorontoCanadayto

Common Plan Values

You can find the full list of server types here.

Server TypevCPUsRAMStorageTrafficMonthly Price (USD)Description
Regular Performance
vc2-1c-1gb11GB25GB1TB$5.00Basic SSD
vc2-1c-2gb12GB55GB2TB$10.00Basic SSD
vc2-2c-4gb24GB80GB3TB$20.00Basic SSD
vc2-4c-8gb48GB160GB4TB$40.00Basic SSD
High Performance (AMD/Intel)
vhp-1c-1gb11GB25GB2TB$6.00NVMe SSD
vhp-1c-2gb12GB50GB3TB$12.00NVMe SSD
vhp-2c-4gb24GB100GB5TB$24.00NVMe SSD
vhp-4c-8gb48GB180GB6TB$48.00NVMe SSD
CPU Optimized
vcp-2c-4gb24GB75GB5TB$40.00CPU Optimized
vcp-4c-8gb48GB150GB6TB$80.00CPU Optimized
vcp-8c-16gb816GB300GB7TB$160.00CPU Optimized

Configure your server

By default, we give you defaults to get up and running quickly, but you might want to make some changes.

Learn more about server configuration →

Example server configuration in .spin.yml

##############################################################
# 👇 Servers - You must set at least one server
##############################################################

servers:
  - server_name: ubuntu-1gb-ord-2
    environment: production
    hardware_profile: vultr_1c_1gb_ubuntu2404

Provision your server

Once you have everything ready, you can provision your server(s) by running this simple command:

Provision your server(s)

spin provision

This command will create your server(s) with Vultr and configure your server(s) to be ready for deployment. There are many more options available when provisioning your server(s). To learn more see the guide below:

Learn more about "spin provision" →

Getting ready for deployment

Now that you have a server ready, you'll want to learn how to get ready for deployment. Next steps are to choose a deployment strategy.

Learn which deployment strategy is right for you →