WooCommerce by default deletes the logs within 30 days. However, it lets you control this feature via
This is a small plugin built on top of that filter that will let you define the number of days you’d like to keep the logs for.
This setting works with
woocommerce_cleanup_logs cron job that runs daily. You’ll want to either wait until the cron job runs, or manually run it if you want to see it in action before that.