Launch your tech mastery with us—your coding journey starts now!
Course Content
Advanced Java

What is the difference between Get and Post?

There are many differences between the Get and Post request. Let’s see these differences:

GET

POST

1) In case of Get request, only limited amount of datacan be sent because data is sent in header.

In case of post request, large amount of data can be sent because data is sent in body.

2) Get request is not secured because data is exposed in URL bar.

Post request is secured because data is not exposed in URL bar.

3) Get request can be bookmarked

Post request cannot be bookmarked

4) Get request is idempotent. It means second request will be ignored until response of first request is delivered.

Post request is non-idempotent

5) Get request is more efficient and used more than Post

Post request is less efficient and used less than get.

Anatomy of Get Request

As we know that data is sent in request header in case of get request. It is the default request type. Let’s see what informations are sent to the server. 

Anatomy of Post Request

As we know, in case of post request original data is sent in message body. Let’s see how informations are passed to the server in case of post request. 

Container

It provides runtime environment for JavaEE (j2ee) applications.It performs many operations that are given below:

  1. Life Cycle Management
  2. Multithreaded support
  3. Object Pooling
  4. Security etc.