By default, WooCommerce Paid Courses enables the ability to link a course to a WooCommerce product. This allows a user to purchase a course on your site. When a course is linked to a WooCommerce product, the lesson content is only viewable to users who have actually purchased the course.
Link a Product to a Course
To link a WooCommerce product to a course, ensure that WooCommerce is installed and activated. Then follow these steps to create a product:
- Go to Products > Add New.
- Add some product details including a title and description.
- In the Product data meta box that appears below the editor, select the Virtual checkbox (this will remove shipping information at checkout).
- Click Save Draft or Publish the product.
Now you’ll need to associate the product with the course(s) you’d like to sell:
- Go to Courses > All Courses and click on the course you would like to attach to your new product.
- In the WooCommerce Product dropdown in the right sidebar, select the product to link to the course.
- Click Update to save.
Users who purchase the course will gain access to its content as soon as the WooCommerce order status is Completed. If you created a virtual product when configuring the course product (as per step 2 above), the order is completed as soon as payment is made.