---
title: Run as a service · Cloudflare Zero Trust docs
description: You can install cloudflared as a system service on Linux and
  Windows, and as a launch agent on macOS. In most cases, we recommend running
  cloudflared as a service. Running as a service helps ensure the availability
  of cloudflared to your origin by allowing the program to start at boot and
  continue running while your origin is online.
lastUpdated: 2025-02-27T03:56:47.000Z
chatbotDeprioritize: false
source_url:
  html: https://developers.cloudflare.com/cloudflare-one/connections/connect-networks/do-more-with-tunnels/local-management/as-a-service/
  md: https://developers.cloudflare.com/cloudflare-one/connections/connect-networks/do-more-with-tunnels/local-management/as-a-service/index.md
---

You can install `cloudflared` as a system service on Linux and Windows, and as a launch agent on macOS. In most cases, we recommend running `cloudflared` as a service. Running as a service helps ensure the availability of `cloudflared` to your origin by allowing the program to start at boot and continue running while your origin is online.

Follow our guides to set up and run `cloudflared` as a service in your environment:

* [Linux](https://developers.cloudflare.com/cloudflare-one/connections/connect-networks/do-more-with-tunnels/local-management/as-a-service/linux/)
* [macOS](https://developers.cloudflare.com/cloudflare-one/connections/connect-networks/do-more-with-tunnels/local-management/as-a-service/macos/)
* [Windows](https://developers.cloudflare.com/cloudflare-one/connections/connect-networks/do-more-with-tunnels/local-management/as-a-service/windows/)
