Creating a Free Membership with a Trial Period (Limited-Time Free Membership)
This can be done using PayPal Pro Forms or Membership Order Button element. To do this, you just need to set 0 as the initial payment and set the trial date (no. of days access).
lease check also this article for some important notes: