You need a PayPal Business Account in order to set up the IPN listener. For instructions on how to set up a business account, click here.
Login in to your PayPal Business account. In the top right corner, click on your name then select 'Account Settings.'
Scroll down and click on 'Website payments' under the 'PRODUCTS & SERVICES' heading.
Click the 'Update' button next to 'Instant payment notifications.'
Click the 'Choose IPN Settings' button.
Using the name of your website, enter the following in the 'Notification URL' field:
https://www.[your site here].com/api/paypal/handler.php
Under 'IPN messages,' select 'Receive IPN messages (Enabled).' Then, click the 'Save' button.