Cloudflare Docs
Cloudflare Zero Trust
Visit Cloudflare Zero Trust on GitHub
Set theme to dark (⇧+D)

Gateway Activity logs

The Activity log shows the individual DNS queries, Network packets, and HTTP requests inspected by Gateway. You can also download encrypted SSH command logs for sessions proxied by Gateway.

To view Activity logs, log in to your Zero Trust dashboard and navigate to Logs > Gateway. Click on an individual row to investigate the event in more detail.

​​ Selective logging

By default, Gateway logs all events, including DNS queries and HTTP requests that are allowed and not a risk. You can choose to disable logs or only log blocked requests. To customize what type of events are recorded, log in to your Zero Trust dashboard and navigate to Settings > Network. Under Activity Logging, indicate your DNS, Network, and HTTP log preferences.

​​ DNS logs

​​ Explanation of the fields

FieldDescription
QueryThe name of the domain that was queried.
EmailThe email address of the user who made the DNS query. This is generated by the WARP client.
ActionWhat Action Gateway applied to the query (for example Allowed or Blocked).
TimeThe timestamp of the DNS query.
Source IPThe public source IP of the DNS query.
Request typeThe DNS query type. This page contains a list of all the DNS query types.
PortThe port that was used to make the DNS query.
Protocol typeThe protocol that was used to make the DNS query (for example, https).
User IDThe ID of the user who made the DNS query. This is generated by the WARP client.
User emailThe email address of the user who made the DNS query. This is generated by the WARP client.
Device IDThe ID of the device that made the DNS query. This is generated by the WARP client.
LocationThe user-configured location from where the DNS query was made.
CategoriesContent categories that the domain belongs to.
Resolver decisionThe reason why Gateway applied a particular Action to the request. Refer to the list of resolver decisions.

​​ Resolver decisions

ValueDescription
allowedByQueryNameDomain or hostname in the query matched an Allow policy.
blockedByQueryNameDomain or hostname in the query matched a Block policy.
allowedRuleIP address in the response matched an Allow policy.
blockedRuleIP address in the response matched a Block policy.
blockedByCategoryDomain or hostname matched a category in a Block policy.
blockedAlwaysCategoryDomain or hostname is always blocked by Cloudflare.
allowedOnNoLocationAllowed because query did not match a Gateway location.
allowedOnNoPolicyMatchAllowed because query did not match a policy.
overrideForSafeSearchResponse was overridden by a SafeSearch policy.
overrideAppliedResponse was overridden by an Override policy.

​​ HTTP logs

​​ Explanation of the fields

FieldDescription
HostThe hostname in the HTTP header for the HTTP request.
MethodThe HTTP method used for the request (e.g., GET, POST, etc.)
DecisionThe Gateway action taken based on the first rule that matched. For example: Allowed, Blocked, Bypass, etc.
TimeThe timestamp of the HTTP request
URLThe full URL of the HTTP request
DeviceThe ID of the device that made the request. This is generated by the WARP client on the device that created the request.
RefererThe Referer request header contains the address of the page making the request.
User AgentThe user agent header sent in the request by the originating device.
File NameFile name string if a file transfer occurred or was attempted.
HTTP versionThe HTTP version of the origin that Gateway connected to on behalf of the user.
Policy detailsThe policy corresponding to the decision Gateway made based on the traffic criteria of the request.

​​ Isolate requests

When a user creates a policy to isolate traffic, the initial request that triggers isolation will be logged as an Isolate decision and the is_isolated field will return false. This is because that initial request is not isolated yet — but it initiates an isolated session.

Since the request is generated in an isolated browser, the result is rendered in the isolated browser and rendered back to the user securely. This request and all subsequent requests in the isolated browser are logged to include the terminal Gateway action that gets applied (e.g. Allow / Block) and the is_isolated field as true.

​​ Network logs

​​ Explanation of the fields

FieldDescription
Source IPThe IP address of the user sending the packet.
Destination IPThe IP address of the packet’s target.
Source portThe source port number for the packet.
Destination portThe destination port number for the packet.
ProtocolThe protocol over which the packet was sent.
SNIThe host whose Server Name Indication (SNI) header Gateway will filter traffic against.
Policy nameThe name of the policy corresponding to the decision Gateway made.
Policy IDThe ID of the policy enforcing the decision Gateway made.
Device IDThe ID of the device that sent the packet. This is generated by the WARP client.
User IDThe ID of the user sending the packet. This is generated by the WARP client.
User emailThe email address of the user sending the packet. This is generated by the WARP client.
CategoriesCategory or categories associated with the packet.

​​ Export Gateway logs with Logpush

You can configure the automatic export of Gateway Activity logs to third-party storage destinations or to security information and event management (SIEM) tools. Once exported, your team can analyze and audit the data as needed.

This feature builds on Cloudflare’s Logpush Service — refer to the Logpush documentation to find a list of available fields forDNS, Network, and HTTP logs.

To enable Logpush for Gateway Activity logs:

  1. In the Zero Trust dashboard, navigate to Logs > Logpush.
  2. Click Connect a service.
  3. Enter a Job name.
  4. From the drop-down menu, choose whether to export the Gateway DNS, Gateway Network, or Gateway HTTP dataset.
  5. Next, select the data fields you want to include in the log.
  6. In the Advanced settings card, choose the timestamp format you prefer, and whether you want to enable logs sampling.
  7. Click Next.
  8. Select the service you want to export your logs to.
  9. Follow the service-specific instructions on the Zero Trust dashboard to validate your destination.

The setup of your Logpush integration is now complete. Logpush will send updated logs every five minutes to your selected destination.

You can configure multiple destinations and add additional fields to your logs by returning to the Logpush page.