Skip to main content

SOAP

Simple Object Access Protocol

Updated 2 min read

Share this page

Send the link, quote the definition with a link back, or show it as a card on your own site.

https://softwaredictionary.org/terms/soap

In short

SOAP is an XML-based messaging protocol for web services that wraps each request and response in a strict envelope, usually defined by a formal WSDL contract.

What is SOAP?

SOAP is a protocol for exchanging structured messages between applications, most often over HTTP. Every message is an XML document with an Envelope that contains an optional Header, for metadata such as security tokens, and a Body that holds the actual request or response. It was standardized by the W3C in the early 2000s and became the backbone of enterprise web services before REST and JSON took over most new APIs.

A SOAP service is usually described by a WSDL (Web Services Description Language) file, an XML contract listing the operations, their inputs and outputs, and the data types, defined with XML Schema. Tools read the WSDL and generate client code, so calling the service feels like calling a local method, which makes SOAP a form of RPC. A family of extensions known as the WS-* standards adds features such as WS-Security for signing and encrypting messages and WS-ReliableMessaging for guaranteed delivery, and errors come back in a standard Fault element.

SOAP is like sending a formal registered letter in an official envelope with a required form inside: heavier and slower than a quick text message, but precise, verifiable, and hard to misread. It remains common in banking, insurance, telecom, healthcare, government, and payment systems, and in integrations with older enterprise software, where strict contracts and built-in security standards are valued.

The usual comparison is SOAP versus REST. SOAP is a protocol with a fixed XML message format and a formal contract, and it typically sends every call as a POST to a single endpoint. REST is an architectural style that uses URLs for resources, standard HTTP methods and status codes, and any data format, most often JSON. REST is lighter and easier to call from browsers, while SOAP offers stricter typing and standardized message-level security. Despite its original name, SOAP isn't especially simple or object-based, and since version 1.2 the name is officially no longer treated as an acronym.

Key takeaways

  • SOAP messages are XML documents with an envelope, an optional header, and a body.
  • A WSDL file formally describes the service's operations and data types.
  • WS-* standards add message-level security and reliable delivery.
  • SOAP is still common in banking, government, telecom, and enterprise integrations.
  • SOAP is a strict protocol; REST is a lighter architectural style that usually uses JSON.

Example

A SOAP 1.2 request messagexml
<!-- Usually sent with HTTP POST to a single service URL -->
<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope"
               xmlns:acc="http://example.com/accounts">
  <soap:Header>
    <!-- Metadata such as authentication tokens goes here -->
  </soap:Header>
  <soap:Body>
    <acc:GetBalance>
      <acc:AccountId>12345</acc:AccountId>
    </acc:GetBalance>
  </soap:Body>
</soap:Envelope>

Readers ask

What is the difference between SOAP and REST?

SOAP is a formal protocol that always uses XML envelopes and usually a WSDL contract. REST is an architectural style built on resource URLs and standard HTTP methods, typically exchanging JSON, which makes it simpler and lighter for most web APIs.

Is SOAP still used?

Yes. Many banks, payment networks, government agencies, and large enterprise systems still run and depend on SOAP services. Most new public APIs, however, use REST, GraphQL, or gRPC.

What is a WSDL file?

A WSDL (Web Services Description Language) file is an XML document that describes a SOAP service: its operations, message formats, data types, and network address. Tools use it to generate client code automatically.

Often compared

See also

Spotted a mistake or something missing on this page?Suggest an edit

Read a random page
Open today's review
Switch to the dark theme
Read this page in Türkçe

More

Settings