What is the difference between SOAP and ASMX

17,352

Basic answer as I think anything too complex may only confuse you further...

ASMX / WCF / Web Service = End-points / places that someone can call to ask a question / send a command etc.

SOAP = Simple Object Access Protocol is the way in which the data goes back and forth between the client and the web-service.

So they are not things you can compare the differences of because they are different things. Think of a web service as a person and SOAP as a language. If both people (web services) speak English (SOAP) they will understand each other and be able to communicate.

Share:
17,352
user1019042
Author by

user1019042

Updated on June 27, 2022

Comments

  • user1019042
    user1019042 almost 2 years

    It sounded an easy for me to know this, but when I googled about it, I couldn't find the exact relationship between SOAP webservices and ASMX webservice. Are they one and the same? Is asmx an implementation of SOAP among others?

    Here is why this is important to me. I have a very simple ASMX webservice. I am investigating how to return complex data. SOAP uses the message envelope to handle data exchange, but my asmx example can easily return it in a C# list. So, should I worry about learning the message envelope in SOAP still!?

    I feel if I know very well the difference between the two, it will be a good start and will help me decide later the techniques I need to use.

  • user1019042
    user1019042 almost 10 years
    So helpful, thank you! This is the example I have started looking at: codeproject.com/Articles/94043/… What made Ayyash's example a SOAP webservice? If I am coding in ASP.Net and C#, do I still need to learn the Message Envelope method of exchanging data?
  • Belogix
    Belogix almost 10 years
    ASMX is seen as the "old" way of creating web services. WCF is newer and more powerful (not always a good thing). They both by default use SOAP (unless you choose otherwise) so it is not something you have to do yourself, they handle / abstract you away from needing to know much about it. Then of course you have Web API (RESTful) which doesn't use SOAP and is the way a lot of people are moving as SOAP has many disadvantages too. To be honest, that article is okay but quite out-dated now and not seen as the "best" approach.
  • MickyD
    MickyD over 6 years
    ASMX is not SOAP
  • Belogix
    Belogix over 3 years
    @MickyD - only just seen this, that is right and why I said "So they are not things you can compare the differences of because they are different things"