DualCube Team has created a very much demanded plugin for WordPress named “MooWoodle”, which make you capable to connect your Moodle site with your wordpress site and sell courses through it.
The plugin is completely free of cost and once you setup the plugin in WordPress/Woo and the activate the webservice in Moodle, you are good to go with the course selling.
According to the plugin description:
It fetches all the courses from your Moodle instance and makes them available for sale, which may be bought by users through WooCommerce. It reduces your effort by synchronising your LMS site with your online store. And when someone purchases a course from the store he/she is automatically gets registered for the course in the LMS site. More over this plugin works with WooCommerce subscription plugin too.
You can download the MooWoodle plugin for the wordpress site from this link (direct link, no popups) – https://wordpress.org/plugins/moowoodle/
Complete setup instructions for both WordPress and Moodle are mentioned here along with screenshots.