Install certificate manually
If your device does not support certificate installation via WARP, you can manually install a Cloudflare certificate. You must add the certificate to both the system keychain and to individual application stores. These steps must be performed on each new device that is to be subject to HTTP filtering.
First, generate and download a Cloudflare certificate. The certificate is available in both .pem
and .crt
file format. Certain applications require the certificate to be in a specific file type, so ensure you download the most appropriate file for your use case.
- In Zero Trust ↗, go to Settings > Resources.
- In Certificates, select Manage.
- Select the certificate you want to download.
- Depending on which format you want, choose Download .pem and/or Download .crt.
To verify your download, use a terminal to check that the downloaded certificate's hash matches the thumbprint listed under Certificate thumbprint. For example:
Some applications require a certificate formatted in the .cer
file type. You can convert your downloaded certificate using OpenSSL ↗:
- Install OpenSSL ↗.
- Download a Cloudflare certificate in
.pem
format. - In a terminal, convert the certificate to DER format with the
.cer
file type:
- Install OpenSSL for Windows ↗.
- Download a Cloudflare certificate in
.pem
format. - In a PowerShell terminal, convert the certificate to DER format with the
.cer
file type:
In macOS, you can choose the keychain in which you want to install the certificate. Each keychain impacts which users will be affected by trusting the root certificate.
Keychain | Access scope |
---|---|
login | The logged in user |
Local Items | Users with access to cached iCloud passwords |
System | All users on the system |
To install a Cloudflare certificate in macOS, you can use either the Keychain Access application or a terminal. Both methods require you to download a certificate in .crt
format.
- Download a Cloudflare certificate.
- Open the
.crt
file in Keychain Access. If prompted, enter your local password. - In Keychain, choose the access option that suits your needs and select Add.
- In the list of certificates, locate the newly installed certificate. Keychain Access will mark this certificate as not trusted. Right-click the certificate and select Get Info.
- Select Trust. Under When using this certificate, select Always Trust.
The root certificate is now installed and ready to be used.
- Download a Cloudflare certificate.
- Open Terminal.
- Add the certificate to your keychain:
This keychain will allow all users on the system access to the certificate. If you want to install the certificate to a different keychain, replace System.keychain
with the name of that keychain.
- Update the OpenSSL CA Store to include the Cloudflare certificate:
The root certificate is now installed and ready to be used.
Windows offers two locations to install the certificate, each impacting which users will be affected by trusting the root certificate.
Store location | Access scope |
---|---|
Current User Store | The logged in user |
Local Machine Store | All users on the system |
- Download a Cloudflare certificate.
- Right-click the certificate file.
- Select Open. If a security warning appears, choose Open to proceed.
- The Certificate window will appear. Select Install Certificate.
- Now choose a Store Location. If a security warning appears, choose Yes to proceed.
- On the next screen, select Browse.
- In the list, choose the Trusted Root Certification Authorities store.
- Select OK, then select Finish.
The root certificate is now installed and ready to be used.
The location where the root certificate should be installed is different depending on your Linux distribution. Follow the specific instructions for your distribution.
The following procedure applies to Debian-based systems, such as Debian, Ubuntu, and Kali Linux.
-
Download a Cloudflare certificate in
.pem
format. -
Install the
ca-certificates
package. -
Copy the certificate to the system, changing the file extension to
.crt
. -
Import the certificate.
The following procedure applies to Red Hat-based systems, such as CentOS and Red Hat Enterprise Linux (RHEL).
-
Download a Cloudflare certificate in both
.crt
and.pem
format. -
Install the
ca-certificates
package. -
Copy both certificates to the trust store.
-
Import the certificate.
NixOS does not use the system certificate store for self updating and instead relies on the certificates found in ~/.nix-profile/etc/ssl/certs
or provided by NIX_SSL_CERT_FILE
at runtime.
- In Safari, download a Cloudflare certificate in
.pem
format. - Open Files and go to Recents.
- Find and open the downloaded certificate file. A message will appear confirming the profile was downloaded. Select Close.
- Open Settings. Select the Profile Downloaded section beneath your Apple Account info. Alternatively, go to General > VPN & Device Management and select the Gateway CA - Cloudflare Managed G1 profile.
- Select Install. If the iOS device is passcode-protected, you will be prompted to enter the passcode.
- A certificate warning will appear. Select Install. If a second prompt appears, select Install again.
- The Profile Installed screen will appear. Select Done. The certificate is now installed. However, before it can be used, it must be trusted by the device.
- In Settings, go to General > About > Certificate Trust Settings. The installed root certificates will be displayed under Enable full trust for root certificates.
- Turn on the Cloudflare certificate.
- A security warning message will appear. Choose Continue.
The root certificate is now installed and ready to be used.
- Download a Cloudflare certificate.
- In Settings, go to Security > Advanced > Encryption & credentials > Install a certificate.
- Select CA certificate.
- Select Install anyway.
- Verify your identity.
- Choose the certificate file you want to install.
The root certificate is now installed and ready to be used.
ChromeOS devices use different methods to store and deploy root certificates. Certificates may fall under the VPN and apps or CA certificate settings. Follow the procedure that corresponds with your device.
-
Download a Cloudflare certificate in
.crt
format. -
Go to Settings > Apps > Google Play Store.
-
Select Manage Android preferences.
-
Go to Security & location > Credentials > Install from SD card.
- In the file open dialog, choose the
certificate.crt
file you downloaded. Select Open. - Enter a name to identify the certificate. Ensure Credential use is set to VPN and apps.
- Select OK.
-
Download a Cloudflare certificate in
.crt
format. -
Go to Settings > Apps > Google Play Store.
-
Select Manage Android preferences.
-
Go to Security & location > Credentials > Install a certificate > CA certificate.
- When prompted with a privacy warning, select Install anyway.
- In the file open dialog, choose the
certificate.crt
file you downloaded. Select Open. - To verify the certificate is installed and trusted, go to Settings > Apps > Google Play Store > Manage Android Preferences > Security > Credentials > Trusted credentials > User.
After adding the Cloudflare certificate to ChromeOS, you may also have to install the certificate in your browser.
Some packages, development tools, and other applications provide options to trust root certificates that will allow for the traffic inspection features of Gateway to work without breaking the application.
All of the applications below first require downloading a Cloudflare certificate with the instructions above. On macOS, the default path to the system keychain database file is /Library/Keychains/System.keychain
. On Windows, the default path is \Cert:\CurrentUser\Root
.
Versions of Chrome before Chrome 113 use the operating system root store ↗ on macOS and Windows. Chrome 113 and newer on macOS and Windows -- and all versions on Linux and ChromeOS -- use the Chrome internal trust store ↗.
To install a Cloudflare certificate to Chrome manually:
- Download a Cloudflare certificate in
.pem
format. - In Chrome, go to Settings > Privacy and security > Security.
- Select Manage certificates.
- Go to Authorities. Select Import.
- In the file open dialog, choose the
certificate.pem
file you downloaded. - In the dialog box, turn on Trust this certificate for identifying websites, Trust this certificate for identifying email users, and Trust this certificate for identifying software makers. Select OK.
- To verify the certificate was installed and trusted, locate it in Authorities.
For information on installing a Cloudflare certificate for organizations, refer to Google's Chrome Enterprise and Education documentation ↗.
To install a Cloudflare certificate to Firefox manually:
- Download a Cloudflare certificate in
.pem
format. - In Firefox, go to Settings > Privacy & Security.
- In Security, select Certificates > View Certificates.
- In Authorities, select Import.
- In the file open dialog, choose the
certificate.pem
file you downloaded. - In the dialog box, turn on Trust this CA to identify websites and Trust this CA to identify email users. Select OK.
- To verify the certificate was installed and trusted, locate it in the table under Cloudflare.
For information on installing a Cloudflare certificate for organizations, refer to this Mozilla support article ↗.
Zero Trust integrates with several mobile device management (MDM) software partners to deploy WARP across devices.
To upload and deploy a Cloudflare certificate in Microsoft Intune:
- Download and convert a Cloudflare certificate to DER format with the
.cer
file type. - In Microsoft Intune, create a trusted certificate profile ↗ with your converted certificate.
For more information, refer to the Microsoft documentation ↗.
To upload and deploy a Cloudflare certificate in Jamf Pro:
- Download and convert a Cloudflare certificate to DER format with the
.cer
file type. - In Jamf Pro, go to Computers > Configuration Profiles to create a computer configuration profile, or go to Devices > Configuration Profiles to create a mobile device configuration profile. Select New.
- Add a name and description for the profile.
- Choose whether you would like Jamf to install the certificate automatically or with self-service, and whether you would like to install the certificate for a single user or all users on the device.
- Select Add > Certificate. Choose the certificate file.
- Uncheck Allow export from keychain.
- Select Scope, then choose which devices or groups to deploy the certificate to.
- Select Save.
For more information, refer to the Jamf Pro documentation ↗.
To upload and deploy a Cloudflare certificate in Kandji:
- Download a Cloudflare certificate in
.crt
format. - In Kandji, upload the certificate ↗ as a PKCS #1-formatted certificate.
To upload and deploy a Cloudflare certificate in Hexnode:
- Download a Cloudflare certificate in
.pem
format. - In Hexnode, follow the directions for adding the certificate to macOS ↗, iOS ↗, and/or Android ↗ devices.
To upload and deploy a Cloudflare certificate in JumpCloud:
- Download a Cloudflare certificate in
.pem
format. - In JumpCloud, upload the certificate ↗.
- Configure a conditional access policy ↗ to deploy the certificate across devices.
Depending on which version of Python you have installed and your configuration, you may need to use either the python
or python3
command. If you use virtual environments ↗, you will need to repeat the following steps within each virtual environment.
The command to install the certificate with Python on Windows automatically includes pip
and certifi
(the default certificate bundle for certificate validation).
- Download a Cloudflare certificate in
.crt
format. - In a PowerShell terminal, install the
certifi
package: - Identify the Python CA store:
- Update the bundle to include the Cloudflare certificate:
- (Optional) Configure your system variables to point to the CA store by adding them to PowerShell's configuration file:
- Restart your terminal.
- Download a Cloudflare certificate in
.pem
format. - In a terminal, install the
certifi
package: - Append the Cloudflare certificate to this CA store by running:
- (Optional) Configure your system variables to point to the CA store by adding them to your shell's configuration file (such as
~/.zshrc
or~/.bash_profile
). For example: - Restart your terminal.
-
Open PowerShell.
-
Run the following command:
This command will output:
-
The
http.sslcainfo
defines the CA Certificate store. To append the Cloudflare certificate to the CA bundle, updatehttp.sslcainfo
.
To configure Git to trust a Cloudflare certificate, run the following command:
- Download a Cloudflare certificate in
.pem
format. - Set the
cafile
configuration to use the Cloudflare certificate:
On some systems you may need to set the following in your path/export list:
To install a certificate for use in a Docker container:
-
Download a Cloudflare certificate in
.pem
format. -
Create a directory for certificates in your Docker project:
-
Verify the certificate was moved to the directory correctly. Your project should have the following structure:
-
Add the certificate to your Docker image:
To add the certificate to your Dockerfile to install it during the build process:
-
Add the certificate install directions to your Dockerfile. For example:
-
Build the Docker image:
-
Verify the certificate was installed:
To add the certificate to your Docker Compose file to install it during runtime:
-
Add the certificate install directions to your
docker-compose.yml
file. For example: -
Run the container:
-
Verify the certificate was installed:
-
The commands below will set the Google Cloud SDK to use a Cloudflare certificate. For more information on configuring the Google Cloud SDK, refer to the Google Cloud documentation ↗.
-
Get curl's
cacert
bundle. -
Download a Cloudflare certificate in
.pem
format. -
Combine the certs into a single
.pem
file. -
Configure Google Cloud to use the combined
.pem
.
If you use Kaniko with Google Cloud SDK, you must install a Cloudflare certificate in the Kaniko CA store ↗. For more information, refer to the gcloud
documentation ↗.
To trust a Cloudflare root certificate in the Google Drive desktop application, follow the procedure for your operating system. These steps require you to download the .pem certificate.
-
In the Finder menu bar, go to Go > Go to Folder. Enter
/Applications/Google Drive.app/Contents/Resources
. -
Find
roots.pem
and copy it to a permanent location, such as your Documents folder. -
Append the contents of
cloudflare.pem
to the end ofroots.pem
. -
Apply the newly created root certificate to your Google Drive application.
You can verify the update with the following command.
-
In File Explorer, go to
\Program Files\Google\Drive File Stream\<version>\config\
. -
Find
roots.pem
and copy it to a permanent location, such as your Documents folder. -
Append the contents of
cloudflare.pem
to the end ofroots.pem
. -
Update the Google Drive registry key.
You can verify the update with the following command.
For more information, refer to the Google documentation ↗ for the TrustedRootCertsFile
setting.
Google Apps Manager (GAM) uses its own certificate store. To add a Cloudflare certificate to GAM, refer to the GAM documentation ↗.
To use a Cloudflare root certificate with AWS CLI, configure it in your AWS configuration files:
To persistently set the location of the certificate:
-
Download a Cloudflare certificate in
.pem
format. -
Locate and open your AWS configuration file ↗.
-
Configure the
ca_bundle
setting ↗ with the location of your certificate. For example: -
Restart your terminal.
To set the location of the certificate for use as an environment variable:
- Download a Cloudflare certificate in
.pem
format. - In a terminal, set the
AWS_CA_BUNDLE
environment variable ↗ to the location of your certificate depending on your operating system. - Restart your terminal.
The command below will set the cafile
↗ configuration inside of composer.json
to use the Cloudflare root certificate. Make sure to download the certificate in the .pem
file type.
Alternatively, you can add this manually to your composer.json
file under the config
key.
To install a Cloudflare root certificate on JetBrains products, refer to the links below:
- AppCode ↗
- CLion ↗
- DataGrip ↗
- DataSpell ↗
- GoLand ↗
- IntelliJ IDEA ↗
- PhpStorm ↗
- PyCharm ↗
- Rider ↗
- WebStorm ↗
To install a Cloudflare root certificate on Eclipse IDE for Java Developers, you must add the certificate to the Java virtual machine (JVM) used by Eclipse.
-
Find the
java.home
value for your Eclipse installation.- In Eclipse, go to Eclipse > About Eclipse (or Help > About Eclipse IDE on Windows and Linux)
- Select Installation Details, then go to Configuration.
- Search for
java.home
, then locate the value. For example:
- Copy the full path after
java.home=
.
-
Add the Cloudflare certificate to Eclipse's JVM:
-
In a terminal, add the
java.home
value you copied as an environment variable. -
Run
keytool
to install and trust the Cloudflare certificate. -
Restart Eclipse.
-
In a terminal, add the
java.home
value you copied as an environment variable. -
Run
keytool
to install and trust the Cloudflare certificate. -
Restart Eclipse.
For more information on adding certificates to Eclipse with keytool
, refer to IBM's documentation ↗.
To trust a Cloudflare root certificate in RubyGems, follow the procedure for your operating system. These steps require you to download a .pem
certificate.
-
Install OpenSSL ↗.
-
In a terminal, format the Cloudflare certificate for Ruby.
-
Create a RubyGems certificate directory in your home folder.
-
Copy the Cloudflare certificate to your RubyGems certificate store.
-
Configure RubyGems to use the certificate.
Alternatively, add the following line to your RubyGems configuration file located in
~/.gemrc
file to globally trust the certificate: -
Restart any terminal sessions.
-
Install OpenSSL for Windows ↗.
-
In a PowerShell terminal, format the Cloudflare certificate for Ruby.
-
Create a RubyGems certificate directory in your home folder.
-
Copy the Cloudflare certificate to your RubyGems certificate store.
-
Configure RubyGems to use the certificate.
Alternatively, add the following line to your RubyGems configuration file located in
$HOME\.gemrc
to globally trust the certificate: -
Restart any terminal sessions.
To trust a Cloudflare root certificate in Minikube, refer to x509: certificate signed by unknown authority ↗.