cheatsheet1999/FrontEndCollection

GET vs POST

cheatsheet1999 opened this issue · 0 comments

GET is used to request a specified resource from server.

Some other notes on GET requests:

  • GET have no body data
  • GET requests can be cached
  • GET requests remain in the browser history
  • GET requests can be bookmarked
  • GET requests should never be used when dealing with sensitive data
  • GET requests have length restrictions
  • GET requests are only used to request data (not modify)

POST is used to send data to a server to create/update a resource.

Some other notes on POST requests:

  • POST have body data
  • POST requests are never cached
  • POST requests do not remain in the browser history
  • POST requests cannot be bookmarked
  • POST requests have no restrictions on data length