Types of web service

Types of web service

We know that web service is a piece of logic provided through a network-accessible endpoint.

The service consumer and provider uses messages to exchange the information.

Web services can be classified as “SOAP” web services and “RESTful” web services.


1. SOAP Web service

It’s based on SOAP protocol which stands for Simple Object Access protocol.

It’s completely XML based protocol which uses SOAP envelope(header and body) to communicate between 2 parties.

It provides additional security with its Web Service security.

Read more about SOAP web services in SOAP web service overview article

2. Restful web service

Rest stands for Representational state transfer.

Restful web service are architectural based services unlike SOAP which is protocol based.

In Rest architecture, everything is treated as resource and which is identified by unique URI.

It can handle any type of data which could be XML, JSON or anything.

Rest is not much secure but we can add some basic authentication or SSL certificates to make it secure.

Read more about Rest services in Rest service overview article

About the Author

Founder of javainsimpleway.com
I love Java and open source technologies and very much passionate about software development.
I like to share my knowledge with others especially on technology 🙂
I have given all the examples as simple as possible to understand for the beginners.
All the code posted on my blog is developed,compiled and tested in my development environment.
If you find any mistakes or bugs, Please drop an email to kb.knowledge.sharing@gmail.com

Connect with me on Facebook for more updates

Share this article on