Setting Multiple profile in Cisco AnyConnect – Windows

I have been using the Cisco AnyConnect as my primary VPN Client for the past few months. The simple view of the client is really impressive and productive.

Whenever I want to connect to my VPN host I will type my VPN host address in the text of VPN client and click connect. It’s pretty easy when we are using only one VPN profile. It will remember our last used setting/profile details with it.

But when I need to switch to another VPN network, I have to delete the VPN host address and retype the new VPN host address. I have searched on the Internet and found how to set the multiple profiles in VPN client.

To set multiple profiles in Cisco AnyConnect VPN client. We have to add an XML config file with name “Profile.xml”

The file has to be placed in the following path

C:\ProgramData\Cisco\Cisco AnyConnect Secure Mobility Client\Profile

Profile.xml

<?xml version="1.0" encoding="UTF-8"?>
<AnyConnectProfile xmlns="http://schemas.xmlsoap.org/encoding/">
<ServerList>
<HostEntry>
<User>username</User>
<HostName>host alias name</HostName>
<HostAddress>host address of vpn</HostAddress>
</HostEntry>
</ServerList>
</AnyConnectProfile>

We have to provide our VPN details inside the HostEntry tag which is under ServerList.

whereas

<User> is username of our VPN account

<HostName> is our alias name of profile

<HostAddress> is URL of VPN host or IP address

Example

<?xml version="1.0" encoding="UTF-8"?>
<AnyConnectProfile xmlns="http://schemas.xmlsoap.org/encoding/">
<ServerList>
<HostEntry>
<User>Pandiyan</User>
<HostName>MyHost</HostName>
<HostAddress>local.pandiyan.com</HostAddress>
</HostEntry>
</ServerList>
<ServerList>
<HostEntry>
<User>Guest</User>
<HostName>MyGuest</HostName>
<HostAddress>guest.pandiyan.com</HostAddress>
</HostEntry>
</ServerList>
</AnyConnectProfile>

Once we have added the profile config file, we have to restart our VPN client instance. Once we restarted the VPN client will look as follows

Cisco

We can able to choose our profile from the drop down, and when we try to load our profile the username will be auto filled using the value of User field in the config file.

MyHost

I have tried these setting on my Windows 10 machine. It’s working fine for me, you guys try out and let me know your feedback in comment section.

 

Happy Working!

36 thoughts on “Setting Multiple profile in Cisco AnyConnect – Windows

  1. MJ Suriya April 27, 2017 / 9:51 am

    Very useful info for all Cisco Users.. Awesome 🙂

    Liked by 2 people

  2. Eugene September 15, 2017 / 6:07 pm

    Nice article, but User tag is not working. Cisco client (4.4) uses last session username instead. Tested on both Linux and Windows boxes.

    Liked by 2 people

    • Pandiyan Murugan September 18, 2017 / 10:36 am

      I’ve experimented this in 3.x version when I wrote the article. Anyway, let me check if I can achieve the same in 4.x as well.

      Like

    • Pandiyan Murugan October 17, 2017 / 6:07 pm

      sorry Eugene, the user tag is not supporting in latest versions.

      Like

      • siddharth mathur April 20, 2018 / 2:58 am

        hi pandiyan, I added a new profile to the location : C:\ProgramData\Cisco\Cisco AnyConnect Secure Mobility Client\Profile restarted client the computer as well but it doesn’t show up on the CISCO anyconnect dropdown list, what should be the next step?

        Like

        • Pandiyan Murugan April 20, 2018 / 7:25 am

          Make sure you don’t any configuration file is not conflicting the settings in the same path.

          Like

  3. m0lt October 11, 2017 / 9:20 am

    Hey ! Very nice Idea but it’s not working. Do you have an Update ?

    Liked by 1 person

  4. Thangam October 17, 2017 / 3:33 pm

    Hey.. Thank you so much for sharing this info. its very helpful to me 🙂

    Liked by 1 person

  5. VoIPEng October 25, 2017 / 1:33 am

    Why does it point to an external SOAP\encoding URL for a local PC -> VPN Client -> Customer Site?

    Like

    • Pandiyan Murugan October 25, 2017 / 11:37 am

      Those lines are just prettifiers, you can set it as empty as well.

      Like

  6. Kim Sørensen November 22, 2017 / 4:10 pm

    Thank you for a very useful article. I am having trouble with the user tag, which I cannot get working. I am using version 4.5.01044.

    Like

    • Pandiyan Murugan November 22, 2017 / 4:30 pm

      Hey Kim, thank you so much.

      The user tag is no longer supported in the latest version.

      Like

  7. Bruce P. December 14, 2017 / 3:02 am

    Great Resource – Thank you, this helped me out quick

    Liked by 1 person

  8. Toth Zoltan July 3, 2018 / 7:53 pm

    Hi!

    It’s not working for me.
    Cisco Anyconnect Secure Mobility Client, ver: 4.5.04029

    Folder path: c:\ProgramData\Cisco\Cisco AnyConnect Secure Mobility Client\Profile\
    My filename is: AnyConnectProfile.xsd

    VPN 1
    vpn.*******.com

    VPN 2
    cevpn.********.com

    What is a problem?

    Liked by 1 person

  9. Carlos Teyul July 3, 2018 / 10:16 pm

    if you want all users to get he multiple site (HQ and DR site) add the profile xml file to the asa configuration> remote access vpn> network client access> anyconnect client software

    Liked by 1 person

  10. maths July 19, 2018 / 5:54 pm

    This didn’t work for me.
    I deleted the old host completely but it didn’t vanished (its still default).
    However, the new host appears now in the list but the username is again the old one??
    I also already changed the default hosts in the preferences_global but nothing changed!
    thx
    maths

    Liked by 1 person

    • Pandiyan Murugan July 19, 2018 / 6:13 pm

      In the latest version, username caching doesn’t support. You can only save the host name.

      Kill the process completely and restart it, you can see the updated host list.

      Like

  11. Martin Goddard March 11, 2020 / 5:56 pm

    Got it working on 4.7.04056. JUst wondering can you save the user names and passwords so which ever profile you select will connect without asking or must you enter usernames and passwords manually

    Good work, thanks for the info and inout on this.

    Like

    • Pandiyan Murugan March 11, 2020 / 6:57 pm

      I wish it should. But only environment details available as of now.

      Like

  12. chris April 10, 2020 / 8:13 pm

    I created my profiles.xml file but I cannot add the txt doc. it only allows me to create a folder. what am I doing wrong? version 4.7.04056

    Like

      • chris pinardi April 10, 2020 / 9:59 pm

        I thought that’s what it was supposed to be. I opened a word doc and followed the profile builder instructions. Now I have a list of all my vpn clients so what is the next step ? I am green so if I appear challenged its because I am !
        this is a sample of how I set up my clients.
        c************p
        D******Z T*******P
        50.***.***.***

        Like

      • chris pinardi April 10, 2020 / 11:39 pm

        I see the error of my ways. I am all set- thanks for putting this out there for everyone

        Like

  13. Giulio Sollazzo June 25, 2020 / 1:50 pm

    Hello, i have a 4.8 client and the two profile are created, but when I connect in the field username was saved the last connected user and not the user saved in a xml,have a idea?
    Thanks

    Like

      • Dinanshu February 28, 2023 / 6:41 pm

        Hi
        I am currently using version 4.10.05 & in this i don’t see profile folder inside Cisco\Cisco AnyConnect Secure Mobility Client. Shall i create a folder on my own & inside that folder profile.xml. Please correct if i am wrong

        Like

        • Pandiyan Murugan May 2, 2023 / 10:36 am

          I’m no longer using the cisco tool.
          Please experiment on your own.

          Like

Leave a comment