VPN key: what you've received and how to add it to an app

WireGuard and OpenVPN configs: differences and importing

WireGuard uses a .conf file and authenticates with a key pair, with no username or password. OpenVPN uses .ovpn with certificates, keys and sometimes a login and password. The files are issued by the provider or administrator.

Updated:

Connection details are not the same as your account: see our breakdown of VPN keys, files and subscription links for more.

How does .conf differ from .ovpn?

The files are intended for different protocols. A config (profile) is the server address and access parameters, like a note with a house address and a door key.

What we compareWireGuard .confOpenVPN .ovpn
Format[Interface] and [Peer] sectionsParameters and certificate/key blocks
Secret dataPrivateKey, optional PresharedKeyPrivate key, tls-crypt key, sometimes a password
Login and passwordNot usedMay be required
ClientWireGuard; on Linux also wg-quickOpenVPN Connect
Import.conf, .zip, QR on mobile.ovpn, URL; drag-and-drop/double-click on desktop
QR codeThe .conf textUse the file or URL

A ZIP archive packs files together like a folder with notes, but it does not itself protect the keys.

What is inside a WireGuard .conf?

One [Interface] section describes your device, and one or more [Peer] sections describe the other side. Your private key stays with you; the server needs the public one.

A fictional sample for reading, not importing:

[Interface]
PrivateKey = YOUR_SECRET
Address = 10.0.0.2/32
DNS = 10.0.0.1

[Peer]
PublicKey = SERVER_KEY
PresharedKey = SHARED_SECRET
AllowedIPs = 0.0.0.0/0, ::/0
Endpoint = vpn.example.com:51820
PersistentKeepalive = 25

Still, do not change Address, DNS or AllowedIPs at random.

What is inside an OpenVPN .ovpn?

Lines set parameters without the leading two dashes. A certificate attests to a side of the connection, like an identity document at an entrance.

A teaching fragment with separate files:

client
dev tun
proto udp
remote vpn.example.com 1194
remote-cert-tls server
ca ca.crt
cert client.crt
key client.key
auth-user-pass

The <ca>, <cert>, <key> blocks embed certificates and keys into the profile; <tls-crypt> is the key protecting the control channel. Separate files are then unnecessary. <auth-user-pass> embeds the login and password.

client.key and the contents of <key> are secret; the certificates are not. Send a profile containing a key or password only over a protected channel.

Where do you get a ready-made file?

Download the file from the provider or request it from the administrator. OpenVPN Connect does not provide a VPN service: the app itself does not grant access to a server.

Sometimes you specifically need a .conf or .ovpn file, for instance for a router or a device without a VLESS client. CitadelVPN includes such WireGuard/OpenVPN configurations in its MAX plan, and support helps with router setup. Before choosing a plan, check with support that your router model and firmware are compatible.

Do not download "free .ovpn" files of unknown origin: you are trusting someone else's server. A label saying "the fastest config" proves nothing about speed.

For vless:// you need the guide on v2rayNG and v2rayN: it is not a WireGuard/OpenVPN profile.

How do you import WireGuard?

Add the profile in the official WireGuard client.

How do you add a file on Android?

  1. Tap the add-tunnel button (a VPN connection).
  2. Choose "Import from file or archive".
  3. Select the .conf or .zip.

For a QR code, choose "Scan from QR code". It contains the .conf text with the private key: do not publish the code or a screenshot of it.

How do you add a file on iPhone or Mac?

  1. Choose "Create from file or archive".
  2. Select the received .conf or .zip.

On iPhone you can also create a tunnel via "Create from QR code".

How do you add a file on Windows?

  1. Choose "Import tunnel(s) from file…".
  2. Open the .conf or .zip with the configurations.

How do you add a file on Windows?

Watch on YouTube

How do you use a file on Linux?

  1. Save the profile at /etc/wireguard/wg0.conf with administrator-only access.
  2. Run wg-quick up wg0 with administrator rights.

These steps require wg-quick to be installed.

How do you import a profile into OpenVPN Connect?

Use the .ovpn or an import address from the provider.

  1. Open the "My Profiles" section.
  2. Tap the add icon.
  3. Choose "Upload File".
  4. Select the .ovpn.
  5. Confirm the import.

On Windows/macOS, drag-and-drop and double-clicking the file work. For a URL, enter the provider's address and sign in: with a password, a second factor or corporate authentication.

However, on Android only one VPN connection works per user or profile. Launching OpenVPN may stop WireGuard.

Why won't the file import?

Usually the text is damaged or the wrong format has been selected. Download the file again: a messaging app may have truncated the key.

Message or situationWhat to check
Invalid keyThat the PrivateKey/PublicKey value is complete, with no stray spaces or quotation marks
Missing sectionThat [Interface] and [Peer] are present
Unknown attributeA typo in a field name, or a parameter belonging to another client
File must be .conf or .zipWhether the file was saved as .conf.txt
The file does not contain a valid WireGuard configurationWhether an HTML page was downloaded instead of the profile
OpenVPN cannot find a certificate or keyWhether the .ovpn references separate files that are missing

Example: instead of tunnel.conf, a sign-in page was downloaded. Log in to your account and download the file again; renaming the page will not help.

What limitations do profiles have?

Can you open a .conf in OpenVPN, or an .ovpn in WireGuard?

No, these are different protocols. Changing the extension does not convert the parameters.

Is it normal for OpenVPN to ask for a password?

Yes, with auth-user-pass and no saved password. WireGuard verifies keys; it has no login field.

Can you import several WireGuard tunnels at once?

Yes, via a .zip with .conf files. Check the number of tunnels added: some files may fail to import.

What should you choose and check before connecting?

Obtain a .conf for WireGuard or an .ovpn for OpenVPN from your provider. Import the original file, and keep the keys and QR codes secret. Before using one profile on several devices, check with the provider whether it is suitable for that.