I suggest you ...

import / Export hosting plans

if you would manage multiple Plesk servers that function very appropriate

183 votes
Sign in
Password icon
Signed in as (Sign out)

We’ll send you updates on this idea

Max shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →


Sign in
Password icon
Signed in as (Sign out)
  • Carl Swart commented  ·   ·  Flag as inappropriate

    A few pointers after having to do it for the umpteenth time. :)

    All needs to be done via SSH on the command line interface.

    # /usr/local/psa/bin/service_plan --xml-info 'SERVICE_PLAN_NAME' >> service_plans.xml

    Dump all your service plans into a service_plans.xml file using the --xml-info command of the service_plan tool supplied by Plesk.

    Then use my code below on the new server to import the service plans from the service_plans.xml file.

    There are differences in the service_plan tool parameters in the different versions of Plesk so, study the 3 arrays, $convert, $deprecated, $sizes and adjust as needed.

    # cat make_service_plans.php

    // Enable for debug output
    define('DEBUG', 1);

    $file = 'service_plans.xml';

    $xml = new DOMDocument();

    $convert = array('wu_script' => 'wuscripts', 'nonexist_mail' => 'no_usr', 'errdocs' => 'err_docs', 'pdir_plesk_stat' => 'webstat_protdir', 'stat_ttl' => 'keep_traf_stat');
    $deprecated = array('fp', 'fp_ssl', 'fp_auth', 'php_handler_type', 'php_safe_mode', 'dns_type', 'same_ssl', 'allow_license_stubs');
    $sizes = ['disk_space', 'quota', 'mbox_quota'];

    $service_plans = $xml->getElementsByTagName('domain-service-plan');

    foreach($service_plans as $service_plan) {
    $command = '/usr/local/psa/bin/service_plan ';
    $service_plan_name = $service_plan->getAttribute('name');
    $service_plan_owner = $service_plan->getAttribute('owner-login');
    // echo "$service_plan_name - Owned by: $service_plan_owner\n";
    $command .= "--create '$service_plan_name' ";
    if ($service_plan_owner != "admin") {
    $command .= "-owner $service_plan_owner ";

    foreach($service_plan->getElementsByTagName('service-plan-item') as $service_plan_item) {
    $name = $service_plan_item->getAttribute('name');
    $value = $service_plan_item->nodeValue;
    if (($name == 'vh_type') && ($value == 'physical')) {
    $name = 'hosting';
    $value = 'true';
    // Remove deprecated settings
    if (in_array($name, $deprecated)) {
    // Convert old settings
    if (in_array($name, array_keys($convert))) {
    $name = $convert[$name];
    // Convert bytes to MB
    if (in_array($name, $sizes)) {
    $value = $value / 1024 / 1024;
    $value .= 'M';
    $command .= "-$name $value ";

    $final_command = trim($command);
    $command_result = `$final_command`;
    if (!preg_match("/(SUCCESS: | successfully )/", $command_result)) {
    print("ERROR: $command_result - $final_command\n");


    Run the script: #php make_service_plans.php

    Hope it helps somebody.

  • Tom iTrena commented  ·   ·  Flag as inappropriate

    And again...
    Meanwhile we have 11 servers with Plesk. All the time we are leasing another one, we have to set up all the 20 Hosting-Plans again.
    And if the plans change, we have to do the same work on every server, again, and again...
    This takes many hours of work!
    So what´s going on? It is very easy to add this feature to Plesk,- we are waiting for...

  • Anonymous commented  ·   ·  Flag as inappropriate

    there is a way to export the plan into XML, but there is no way to import this yet:

    /usr/local/psa/bin/service_plan -x "Plan Name"

    i wont post any solutions to this as it is untested, but a crafty admin could make a create statement for service_plan using sed on this xml output.

  • Greg Conway commented  ·   ·  Flag as inappropriate

    @Sergey L (Director of Program Management, Plesk)

    Where are these examples to which you refer? Could you please provide an example of how to import/export hosting plans here (where many people are looking for such functionality), or provide a link?

  • [Deleted User] commented  ·   ·  Flag as inappropriate

    Would it be possible to add an import/export feature to the subscription plans settings (customer-service-plan/list), so we can have exactly same features enabled on all new created Plesk panels

  • COVI commented  ·   ·  Flag as inappropriate

    Allow to export or migrate Service Packages and Add-Ons as single option and also hold them on Abbonements while migrating

  • Jasper van Veen commented  ·   ·  Flag as inappropriate

    @Mike switch to cPanel or DirectAdmin. They do actually have an option to transfer your setup plans in a breeze, unlike Plesk. We tested cPanel for 4 months and we are now transfering, or better said migrating, all our 60+ servers over to cPanel.

    We will keep about 4 or 5 servers with Plesk, for the customers who want to stay on Plesk, but most are very content with cPanel as well. We also have several servers with DirectAdmin (which is really cheap). So if you want an easy way to duplicate / transfer service plans, than I would recommend you to make the switch. Plesk isn't what it used to be.

  • AdminSergey L (Director of Program Management, Plesk International GmbH) commented  ·   ·  Flag as inappropriate

    There is already a reliable way to transfer or copy service plans with quite easy CLI and you can find some examples below. Delivering this request will add some convenience, surely, but it doesn't seem to be in the top - perhaps because quite many hosters already utilize CLI and thus are not disturbed too much with this problem. On the other end, they might want one of 30+ higher voted functions first and we are taking those votes quite seriously. i hope it explains why this request isn't delivered yet

    If that is critical for you, wouldn't it be more productive to start using CLI now?

  • [Deleted User] commented  ·   ·  Flag as inappropriate


    I am getting tired of waiting. We are only getting BS options with Plesk nowadays. Not even a decent websitebuilder, but who cares, there are plenty alternatives for this.

    So ****; add the ability to also transfer full service plans from one Plesk to another including all settings without issues. Please....


  • TheSurge commented  ·   ·  Flag as inappropriate

    i also support this feature and i have no clue what cli is. there should be an option in the plesk control panel. it alreadys costs enough, so add this feature asap.

  • Larsen commented  ·   ·  Flag as inappropriate

    @Mike: see my comment below regarding CLI.

    For example:
    /opt/psa/bin/service_plan --create "Domain only" -webmail horde -overuse not_suspend_notify -hosting true -max_maillists 0 \
    -max_webapps 0 -webstat none -log_rotate true -log_bytime monthly -log_max_num_files 1 \
    -log_compress true -no_usr reject -quota 5M -disk_space 5M -max_box 1 -mbox_quota 2500K \
    -max_db 0 -max_traffic 500M -max_wu 5 -php false -manage_log false -ssl true -max_site 10 -max_unity_mobile_sites 0

  • [Deleted User] commented  ·   ·  Flag as inappropriate

    I vote for import/export function for 'Service Plans' as well. It's currently way, way too much work to re-create the necessary plans on a new server.

    I don't understand why this feature wasn't implented years ago. It's a necessity when you have several servers like us.

    Because of this we are currently thinking about dropping Plesk all together and switch to a different brand. So I can only hope this will be implented asap, otherwise we won't have any other choice than to switch.

    We setup 2 new servers a week and redoing the whole "Service Plans" with all the correct settings, is just too time consuming...

← Previous 1

Feedback and Knowledge Base