Title: Create a clone programmatically with PHP function
Last modified: December 19, 2023

---

# Create a clone programmatically with PHP function

 *  Resolved [karlosuccess](https://wordpress.org/support/users/karlosuccess/)
 * (@karlosuccess)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/create-a-clone-programmatically-with-php-function/)
 * Hello,
 * I keep sending support tickets and chat messages to the main site of NS cloner
   but no one never replies.
   [https://wpsitecloner.com/](https://wpsitecloner.com/)
   [https://wordpress.org/support/topic/when-user-create-a-site-clone-should-be-created/](https://wordpress.org/support/topic/when-user-create-a-site-clone-should-be-created/)————————-
   Anyway, this is what I need:
 * I have a custom front end user registration form to register to my network.
 * When a new user registers, I need to create a clone site for this user.
 * The question is: In the free -or- the paid plugin version, is there a function
   such as, in example, create_clone_site( $template_site_id ) that can be used 
   to create a clone programmatically?
 * Ideally, we would pass the id of the sub site that is being used as template 
   in the network to create a new clone from that site.
 * I hope it makes sense. It has to be a php function so it can be done programatically.
 * Please advise. I need this urgently.
 * Thank you

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [Never Settle](https://wordpress.org/support/users/neversettle/)
 * (@neversettle)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/create-a-clone-programmatically-with-php-function/#post-17290933)
 * Hey [@karlosuccess](https://wordpress.org/support/users/karlosuccess/),
 * Hope you are well. We did respond to your post on [https://wordpress.org/support/topic/when-user-create-a-site-clone-should-be-created/](https://wordpress.org/support/topic/when-user-create-a-site-clone-should-be-created/).
   To instantiate a clone within a different plugin, please look at [https://support.neversettle.it/article/22-how-to-call-ns-cloner-to-copy-sites-from-other-plugins](https://support.neversettle.it/article/22-how-to-call-ns-cloner-to-copy-sites-from-other-plugins)
 * Warm Regards
 *  Thread Starter [karlosuccess](https://wordpress.org/support/users/karlosuccess/)
 * (@karlosuccess)
 * [2 years, 5 months ago](https://wordpress.org/support/topic/create-a-clone-programmatically-with-php-function/#post-17292118)
 * Yes, you guys always replied very soon and promptly this support forum. 
   Thank
   you very much for the info! I will take a look!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Create a clone programmatically with PHP function’ is closed to new replies.

 * ![](https://ps.w.org/ns-cloner-site-copier/assets/icon-256x256.gif?rev=2323308)
 * [NS Cloner - Site Copier](https://wordpress.org/plugins/ns-cloner-site-copier/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/ns-cloner-site-copier/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/ns-cloner-site-copier/)
 * [Active Topics](https://wordpress.org/support/plugin/ns-cloner-site-copier/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/ns-cloner-site-copier/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/ns-cloner-site-copier/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [karlosuccess](https://wordpress.org/support/users/karlosuccess/)
 * Last activity: [2 years, 5 months ago](https://wordpress.org/support/topic/create-a-clone-programmatically-with-php-function/#post-17292118)
 * Status: resolved