This topic describes how to enable Log Service for WAF in the WAF console. After your website is added to Web Application Firewall (WAF), you can enable Log Service for WAF in the WAF console to query and analyze access logs based on your business requirements.


  • A subscription WAF instance of the Pro edition or a higher edition is purchased. For more information, see Activate Alibaba Cloud WAF.
  • Your website is added to WAF.

Background information

You can use the Log Service for WAF feature to collect diversified log data in real time from your website that is added to WAF, query and analyze the collected log data in real time, and display results on dashboards. Log Service for WAF can meet the classified protection requirements as well as your website protection and operations requirements.


  1. Log on to the Web Application Firewall console.
  2. In the top navigation bar, select the resource group to which the instance belongs and the region, Mainland China or International, in which the instance is deployed.
  3. In the left-side navigation pane, choose Log Management > Log Service .
  4. On the Log Service page, click Upgrade in the upper-right corner.
    Note If you have enabled Log Service for WAF, the Upgrade button is not displayed.
  5. On the Upgrade/Downgrade page, select YES for Access Log Service, and specify Log Storage Period and Log Storage Size based on your business requirements.Configurations on the buy page
  6. Click Buy Now and complete the payment.
    Note For more information about the billing standards of Log Service for WAF, see Billing.
  7. Go back to the Log Service page. Click Authorize Now.
  8. On the Cloud Resource Access Authorization page, click Confirm Authorization Policy to authorize WAF to write log data into your dedicated Logstore.
    Log Service for WAF is then enabled and authorized.
  9. On the Log Service page, select the domain of your website that is added to WAF and turn on Status next to the domain.


Then, all log data from the domain of your website that is added to WAF is collected in real time. You can query and analyze collected log data in real time.